Jump to content

Angelino

Members
  • Posts

    14
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Angelino's Achievements

Jr. Member

Jr. Member (3/6)

2

Reputation

  1. @monollonom Yes pages sort on `name` if i use `name, status`. Using `title, status` doenst work. But when i use `status, title` this works.
  2. @monollonom Thanks for this module! I’m not sure if this is a bug, but when I use name, status, it doesn’t sort. I need to use status, name instead, which is strange.
  3. @Alpina Here is my `nginx.conf`file: server { listen 80; server_name default; # Here you need to change default with your site root /var/www/html; # Ensure this path is correct and points to the ProcessWire files index index.php index.html index.htm; location / { try_files $uri $uri/ /index.php?$query_string; } location ~ \.php$ { include fastcgi_params; fastcgi_pass php:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; } location ~ /\.ht { deny all; } } and my compose.yml nginx nginx: container_name: nginx image: nginx:alpine ports: - "80:80" volumes: - ./nginx/nginx.conf:/etc/nginx/conf.d/default.conf - ../code/:/var/www/html # here is ../code my root folder depends_on: - php - mysql networks: - boilerplate # this is custom, your network need to come here
  4. My apologies; there was a misconfiguration in my Nginx settings: server_name default; I changed it on the server to the correct domain: server_name example.com www.example.com; Now it works, and previews from ProcessWire are directed to the correct URL.
  5. I got a website like www.example.com/nl/ also on /en/ /fr/. Now if i'm in processwire making my content and want to see my preview on the SAVE button like save + view then the preview jumps to https://default/nl/....../ and not my domainname? My main language is /nl/ ofcourse. Anything i missed in the settings? I set my $config->httpHosts already filled in my domains.
  6. Ok, i looked at the above post. But i managed to make myself a bit of a solution. I did use AdminStyleRock from it, i liked this module. Here is my package.json: { "name": "code", "version": "1.0.0", "description": "", "main": "index.js", "scripts": { "watch": "cross-env NODE_ENV=development webpack --watch --config webpack.config.js", "build": "cross-env NODE_ENV=production webpack --config webpack.config.js" }, "keywords": [], "author": "", "license": "ISC", "devDependencies": { "@babel/core": "^7.24.9", "@babel/preset-env": "^7.24.8", "@fortawesome/fontawesome-free": "^6.6.0", "autoprefixer": "^10.4.19", "babel-loader": "^9.1.3", "browser-sync": "^2.29.3", "browser-sync-webpack-plugin": "^2.3.0", "copy-webpack-plugin": "^12.0.2", "cross-env": "^7.0.3", "css-loader": "^7.1.2", "dotenv": "^16.4.5", "html-webpack-plugin": "^5.6.0", "mini-css-extract-plugin": "^2.9.0", "postcss": "^8.4.39", "postcss-loader": "^8.1.1", "sass": "^1.77.8", "sass-loader": "^14.2.1", "style-loader": "^4.0.0", "tailwindcss": "^3.4.6", "webpack": "^5.93.0", "webpack-cli": "^5.1.4", "webpack-dev-server": "^5.0.4", "webpack-manifest-plugin": "^5.0.0" } } My webpack.config.js: const path = require('path'); const MiniCssExtractPlugin = require("mini-css-extract-plugin"); const BrowserSyncPlugin = require('browser-sync-webpack-plugin'); const { WebpackManifestPlugin } = require('webpack-manifest-plugin'); const CopyPlugin = require("copy-webpack-plugin"); const devMode = process.env.NODE_ENV !== "production"; const config = { mode: devMode ? 'development' : 'production', entry: { index: path.resolve(__dirname, "./src/index.js"), }, output: { path: path.resolve(__dirname, 'dist'), filename: devMode ? "[name].js" : "[name].[contenthash].js", clean: true, }, module: { rules: [ { test: /\.(css|scss)$/i, use: [MiniCssExtractPlugin.loader, 'css-loader', 'postcss-loader', 'sass-loader'], }, { test: /\.(png|svg|jpg|jpeg|gif)$/i, type: 'asset/resource', }, { test: /\.(woff|woff2|eot|ttf|otf)$/i, type: 'asset/resource', generator: { filename: './fonts/[name][ext]', }, }, ], }, plugins: [ new MiniCssExtractPlugin({ filename: devMode ? "[name].css" : "[name].[contenthash].css", }), new WebpackManifestPlugin({ fileName: path.resolve(__dirname, 'dist/manifest.json'), publicPath: '/dist/', filter: (fileDescriptor) => { // Exclude .png, .jpg, and .ttf files etc. from the manifest const excludedExtensions = ['.png', '.jpg', 'svg', 'jpeg', 'gif', '.ttf', 'woff', 'woff2', 'eot', 'otf']; return !excludedExtensions.some(extension => fileDescriptor.path.endsWith(extension)); }, }), new CopyPlugin({ patterns: [ { from: "./src/assets/fonts", to: "fonts" }, { from: "./src/assets/images", to: "images" }, ], }), ], }; if (devMode) { config.plugins.push( new BrowserSyncPlugin({ host: 'localhost', port: 3000, files: ['../site/templates/**/*.php'], proxy: 'http://place here your localhost/', }) ); } module.exports = config; My tailwindcss.config.js: /** @type {import('tailwindcss').Config} */ module.exports = { content: ["./site/templates/**/*.php"], theme: { screens: { 'sm': '640px', 'md': '768px', 'lg': '1024px', 'xl': '1280px', '2xl': '1536px', }, extend: { fontFamily: { 'arpona': ['Arpona', 'sans-serif'], 'avantbold': ['ITCAvantGardeStdBold', 'sans-serif'], 'avantnormal': ['AvantGardeStdLight', 'sans-serif'], }, }, plugins: [], } My postcss.config.js: module.exports = { plugins: [ require('tailwindcss'), require('./tailwind.config.js'), require('autoprefixer') ], }; My SCSS tailwindcss file: @import "tailwindcss/base"; @import "tailwindcss/components"; @import "tailwindcss/utilities"; // Fontawesome import and custom font-face $fa-font-path: '~@fortawesome/fontawesome-free/webfonts'; @import '~@fortawesome/fontawesome-free/scss/fontawesome'; @import '~@fortawesome/fontawesome-free/scss/solid'; @import '~@fortawesome/fontawesome-free/scss/regular'; // Make font-family a custom value, if you using a font like: // Arpona_ExtraBold = Arpona // or ITCAvantGardeStd-Bold = ITCAvantGardeStdBold @font-face { font-family: 'Arpona'; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/Arpona_ExtraBold.otf"); } @font-face { font-family: 'ITCAvantGardeStdBold'; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/ITCAvantGardeStd-Bold.ttf"); } @font-face { font-family: 'AvantGardeStdLight'; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/ITCAvantGardeStd-Bk.ttf"); } With this configurated you can use tailwindcss, also on save the webpage will reload. npm run watch I hope i can help out some users.
  7. I'm aware of that Processwire is a headless CMS, but is there is nothing that is already setup to use in 2024? Like a Vite or a Webpack boilerplate to use with tailwindcss. Maybe someone that has already setup this things in the community and will share the config files? Hot reload would be nice to, i got some old projects but they use Grunt butisn't this oldschool in 2024. I spended hours already to get setup things like this myself so a push in the right direction would be nice to have. Thanks in advance.
  8. @wbmnfktr Thanks, this did it for me. Many thanks i wouldn't have found this. ?
  9. I have multiple language website, the default page is https://double-digit.eu/ and is english but can i force this page to set this with /en for english https://double-digit.eu/en/ ? Because my other language is dutch and there is /nl/ after the URL. Or is this not needed, SEO wise?
  10. Thanks, for the reply. My version is 3.0.152 dev. So it can be this.
  11. OK, i solved it. But its very strange situation. Like this i had to hide NL again. I activate my other language FR now, saved it. Then going back to my page and selected tab FR above the inputfield, put in my translation and save. NOW the inputfield was filled in, so i activated NL back again and then it worked aswell.
  12. So, when i type in the translation of the english word and press Save it saves in Database but it is not showing up in Processwire? Anyone has any advice? Must say if im in local environment it is showing up, its not in staging and production. Its like value="" is not present at that inputfield.
  13. Ok, i think i found it. For some reason the hidden checkbox was checked. I unchecked it and now i got my language tabs working. Now i need to find how to setup a custom field, i guess with __("......") or _x(".......")
  14. Hello, For a website we using processwire as CMS, now it is single language in Dutch we want to add FR en EN to it. But how to get these FR and EN tabs above the content labels? Even my template files are not accessable in the site translations files? I added all language packages and i added the languages french en english in the setup aswell. Thanks in advance.
×
×
  • Create New...