Forum Replies Created

Viewing 15 replies - 1 through 15 (of 68 total)
  • @badasswp I’ve reviewed the translations. While the work is complete, I noticed that several terms from the Arabic glossary weren’t translated accurately. Even fundamental terminology—such as “plugin”—was mistranslated. I’m happy to assist this time, but I’d recommend prioritizing human translators over automated or AI tools for future reviews. Doing so will show more respect to the GTEs and ensure consistency with established terminology.

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    Hello @sirlouen I did what you asked:

    To get the source code of wp-config.php

    docker exec ad7119d7599006247378c85362dceba9-tests-wordpress-1 cat /var/www/html/wp-config.php

    I got this:

    <?php
    /**
    * The base configuration for WordPress
    *
    * The wp-config.php creation script uses this file during the installation.
    * You don't have to use the website, you can copy this file to "wp-config.php"
    * and fill in the values.
    *
    * This file contains the following configurations:
    *
    * * Database settings
    * * Secret keys
    * * Database table prefix
    * * ABSPATH
    *
    * This has been slightly modified (to read environment variables) for use in Docker.
    *
    * @link https://developer.ww.wp.xz.cn/advanced-administration/wordpress/wp-config/
    *
    * @package WordPress
    */

    // IMPORTANT: this file needs to stay in-sync with https://github.com/WordPress/WordPress/blob/master/wp-config-sample.php
    // (it gets parsed by the upstream wizard in https://github.com/WordPress/WordPress/blob/f27cb65e1ef25d11b535695a660e7282b98eb742/wp-admin/setup-config.php#L356-L392)

    // a helper function to lookup "env_FILE", "env", then fallback
    if (!function_exists('getenv_docker')) {
    // https://github.com/docker-library/wordpress/issues/588 (WP-CLI will load this file 2x)
    function getenv_docker($env, $default) {
    if ($fileEnv = getenv($env . '_FILE')) {
    return rtrim(file_get_contents($fileEnv), "\r\n");
    }
    else if (($val = getenv($env)) !== false) {
    return $val;
    }
    else {
    return $default;
    }
    }
    }

    // ** Database settings - You can get this info from your web host ** //
    /** The name of the database for WordPress */
    define( 'DB_NAME', getenv_docker('WORDPRESS_DB_NAME', 'wordpress') );

    /** Database username */
    define( 'DB_USER', getenv_docker('WORDPRESS_DB_USER', 'example username') );

    /** Database password */
    define( 'DB_PASSWORD', getenv_docker('WORDPRESS_DB_PASSWORD', 'example password') );

    /**
    * Docker image fallback values above are sourced from the official WordPress installation wizard:
    * https://github.com/WordPress/WordPress/blob/1356f6537220ffdc32b9dad2a6cdbe2d010b7a88/wp-admin/setup-config.php#L224-L238
    * (However, using "example username" and "example password" in your database is strongly discouraged. Please use strong, random credentials!)
    */

    /** Database hostname */
    define( 'DB_HOST', getenv_docker('WORDPRESS_DB_HOST', 'mysql') );

    /** Database charset to use in creating database tables. */
    define( 'DB_CHARSET', getenv_docker('WORDPRESS_DB_CHARSET', 'utf8mb4') );

    /** The database collate type. Don't change this if in doubt. */
    define( 'DB_COLLATE', getenv_docker('WORDPRESS_DB_COLLATE', '') );

    /**#@+
    * Authentication unique keys and salts.
    *
    * Change these to different unique phrases! You can generate these using
    * the {@link https://api.ww.wp.xz.cn/secret-key/1.1/salt/ ww.wp.xz.cn secret-key service}.
    *
    * You can change these at any point in time to invalidate all existing cookies.
    * This will force all users to have to log in again.
    *
    * @since 2.6.0
    */
    define( 'AUTH_KEY', getenv_docker('WORDPRESS_AUTH_KEY', '4c883adb84e877c6c8dc13ce1f832e2790d56e0a') );
    define( 'SECURE_AUTH_KEY', getenv_docker('WORDPRESS_SECURE_AUTH_KEY', '988c5b930e1eb9a61de32e10372ef6df29c1b093') );
    define( 'LOGGED_IN_KEY', getenv_docker('WORDPRESS_LOGGED_IN_KEY', '90507008ff39156add9aa269139e7dfd52a0f089') );
    define( 'NONCE_KEY', getenv_docker('WORDPRESS_NONCE_KEY', 'e572d7a761dab5a2bd528a243afb91a4c375dac5') );
    define( 'AUTH_SALT', getenv_docker('WORDPRESS_AUTH_SALT', '3dd1e234262581f15d2b5a11769ffd32d58769c7') );
    define( 'SECURE_AUTH_SALT', getenv_docker('WORDPRESS_SECURE_AUTH_SALT', '836227ef9b0cdb3b31b940ce14ed6e11753790b3') );
    define( 'LOGGED_IN_SALT', getenv_docker('WORDPRESS_LOGGED_IN_SALT', '47bb0c7368b11aa0631c5d0959d6e3e032d7f6b9') );
    define( 'NONCE_SALT', getenv_docker('WORDPRESS_NONCE_SALT', '713572ea627647b6fd37d0453feae5c15c08c2a4') );
    // (See also https://wordpress.stackexchange.com/a/152905/199287)

    /**#@-*/

    /**
    * WordPress database table prefix.
    *
    * You can have multiple installations in one database if you give each
    * a unique prefix. Only numbers, letters, and underscores please!
    *
    * At the installation time, database tables are created with the specified prefix.
    * Changing this value after WordPress is installed will make your site think
    * it has not been installed.
    *
    * @link https://developer.ww.wp.xz.cn/advanced-administration/wordpress/wp-config/#table-prefix
    */
    $table_prefix = getenv_docker('WORDPRESS_TABLE_PREFIX', 'wp_');

    /**
    * For developers: WordPress debugging mode.
    *
    * Change this to true to enable the display of notices during development.
    * It is strongly recommended that plugin and theme developers use WP_DEBUG
    * in their development environments.
    *
    * For information on other constants that can be used for debugging,
    * visit the documentation.
    *
    * @link https://developer.ww.wp.xz.cn/advanced-administration/debug/debug-wordpress/
    */
    define( 'FS_METHOD', 'direct' );
    define( 'SCRIPT_DEBUG', false );
    define( 'WP_ENVIRONMENT_TYPE', 'development' );
    define( 'WP_PHP_BINARY', 'php' );
    define( 'WP_TESTS_EMAIL', '[email protected]' );
    define( 'WP_TESTS_TITLE', 'Test Blog' );
    define( 'WP_TESTS_DOMAIN', 'localhost:8889' );
    define( 'WP_SITEURL', 'http://localhost:8889' );
    define( 'WP_HOME', 'http://localhost:8889' );
    define( 'WP_DEBUG_LOG', true );
    define( 'WP_DEBUG_DISPLAY', true );
    define( 'port', 80 );
    define( 'WP_DEBUG', false );

    /* Add any custom values between this line and the "stop editing" line. */

    // If we're behind a proxy server and using HTTPS, we need to alert WordPress of that fact
    // see also https://ww.wp.xz.cn/support/article/administration-over-ssl/#using-a-reverse-proxy
    if (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && strpos($_SERVER['HTTP_X_FORWARDED_PROTO'], 'https') !== false) {
    $_SERVER['HTTPS'] = 'on';
    }
    // (we include this by default because reverse proxying is extremely common in container environments)

    if ($configExtra = getenv_docker('WORDPRESS_CONFIG_EXTRA', '')) {
    eval($configExtra);
    }

    /* That's all, stop editing! Happy publishing. */

    /** Absolute path to the WordPress directory. */
    if ( ! defined( 'ABSPATH' ) ) {
    define( 'ABSPATH', __DIR__ . '/' );
    }

    /** Sets up WordPress vars and included files. */
    require_once ABSPATH . 'wp-settings.php';


    ———–
    Concerning the steps I followed installing wp-env in a new folder, I did the following, knowing that wp-env was already globally installed and docker desktop already running before:

    1- Created a folder: wp-env support
    2- ~/Documents/wp-env support $ npm install @wordpress/env –save-dev

    added 171 packages in 7s

    34 packages are looking for funding
    run npm fund for details

    3- ~/Documents/wp-env support $ npx wp-env start
    ⚠ Warning: could not find a .wp-env.json configuration file and could not determine if ‘/home/fakhri/Documents/wp-env support ‘ is a WordPress installation, a plugin, or a theme.
    WordPress development site started at http://localhost:8888
    WordPress test site started at http://localhost:8889
    MySQL is listening on port 37089
    MySQL for automated testing is listening on port 44239

    ✔ Done! (in 149s 274ms)

    4- Accessed http://localhost:8888/wp-admin

    got the 2 site health critical issues we talked about before:

    5- npx wp-env stop

    6- created a .wp-env.json

    {
    "core": "https://ww.wp.xz.cn/latest.zip",
    "phpVersion": "8.2",
    "mappings": {},
    "config": {
    "WP_DEBUG": true,
    "WP_DEBUG_LOG": true,
    "WP_DEBUG_DISPLAY": true,
    "SCRIPT_DEBUG": true,
    "WP_ENVIRONMENT_TYPE": "development"
    },
    "plugins": [],
    "themes": ["https://downloads.wp.xz.cn/theme/twentytwentyfive.zip"]
    }

    7 – I ran: npx wp-env start
    8- logged to http://localhost:8888

    9- Site health 2 critical issues still there

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    @mridulgoswami Do you suggest opening a ticket in Trac or support forum?

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    @sirlouen correct me if I am wrong, I think the default port is 8888 as in the documentation here:

    The local environment will be available at http://localhost:8888 (Username: admin, Password: password).

    I did a the grep search you recommended to run and it returned a lots of stuff:

    ~/Documents/wp-env-test$ grep -r 8888
    node_modules/@types/node/dns.d.ts: * '[2001:4860:4860::8888]',
    node_modules/@types/node/dns.d.ts: * '[2001:4860:4860::8888]:1053',
    node_modules/@types/node/dns.d.ts: * '2001:4860:4860::8888',
    node_modules/@types/node/dns.d.ts: * '[2001:4860:4860::8888]:1053',
    node_modules/@types/node/test.d.ts: * setTimeout(() => results.push(3), 8888);
    node_modules/@types/node/test.d.ts: * setTimeout(() => results.push(2), 8888);
    node_modules/@types/node/url.d.ts: * const myURL = new URL('https://example.org:8888');
    node_modules/@types/node/url.d.ts: * // Prints 8888
    node_modules/@types/node/dns/promises.d.ts: * '2001:4860:4860::8888',
    node_modules/@types/node/dns/promises.d.ts: * '[2001:4860:4860::8888]:1053',
    node_modules/@types/node/dns/promises.d.ts: * '[2001:4860:4860::8888]',
    node_modules/@types/node/dns/promises.d.ts: * '[2001:4860:4860::8888]:1053',
    node_modules/@wordpress/env/README.md:The local environment will be available at http://localhost:8888 (Username:
    admin, Password: password).
    node_modules/@wordpress/env/README.md:Finally, navigate to http://localhost:8888 in your web browser to see WordPress running with the local WordPress plugin or theme running and activated. Default login credentials are username: admin password: password.
    node_modules/@wordpress/env/README.md:In this table, by default, you should see three entries: wordpress with port 8888, tests-wordpress with port 8889 and mariadb with port 3306.
    node_modules/@wordpress/env/README.md:By default wp-env uses port 8888, meaning that the local environment will be available at http://localhost:8888.
    node_modules/@wordpress/env/README.md:Starts WordPress for development on port 8888 (​http://localhost:8888​)
    node_modules/@wordpress/env/README.md:| "port" | integer | 8888 (8889 for the tests instance) | The primary port number to use for the installation. You'll access the instance through the port: 'http://localhost:8888'. |
    node_modules/@wordpress/env/README.md:On the development instance, cwd will be mapped as a plugin, one-theme will be mapped as a theme, KEY_1 will be set to true, and KEY_2 will be set to false. Also note that the default port, 8888, will be used as well.
    node_modules/@wordpress/env/lib/cli.js: '8888',
    node_modules/@wordpress/env/lib/cli.js: 'http://localhost:8888'
    node_modules/@wordpress/env/lib/config/parse-config.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/post-process-config.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/post-process-config.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/post-process-config.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/validate-config.js: checkPort( 'test.json', 'test', 8888 )
    node_modules/@wordpress/env/lib/config/test/validate-config.js: checkValidURL( 'test.json', 'test', 'https://test.co.uk:8888' )
    node_modules/@wordpress/env/lib/config/test/validate-config.js: 'http://test.co.uk:8888/test?test=test#test'
    node_modules/@wordpress/env/lib/config/test/parse-config.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/merge-configs.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/merge-configs.js: port: 8888,
    node_modules/@wordpress/env/lib/config/test/config-integration.js: expect( config.env.development.port ).toEqual( 8888 );
    node_modules/@wordpress/env/lib/config/test/snapshots/config-integration.js.snap: "WP_HOME": "http://localhost:8888",
    node_modules/@wordpress/env/lib/config/test/snapshots/config-integration.js.snap: "WP_SITEURL": "http://localhost:8888",
    node_modules/@wordpress/env/lib/config/test/snapshots/config-integration.js.snap: "WP_TESTS_DOMAIN": "localhost:8888",
    node_modules/@wordpress/env/lib/config/test/snapshots/config-integration.js.snap: "port": 8888,
    node_modules/@wordpress/env/lib/test/build-docker-compose-config.js: port: 8888,
    node_modules/docker-compose/dist/old/v2/index.test.js:// const result = await compose.port('web', 8888, config)
    node_modules/docker-compose/dist/old/v2/index.test.js:// expect(result.data.port).toBe(8888)
    node_modules/docker-compose/dist/old/v2/index.test.js:// const port = await compose.port('web', 8888, config)
    node_modules/docker-compose/dist/old/v1/index.test.js: return [4 /yield/, compose.port('web', 8888, config)];
    node_modules/docker-compose/dist/old/v1/index.test.js: expect(result.data.port).toBe(8888);
    node_modules/docker-compose/dist/old/v1/index.test.js: return [4 /yield/, compose.port('web', 8888, config)];


    Just a heads up, I’ve added the line below to the .wp-env.json file, right below the phpVersion line. This will make the port change permanent.

    "port": 80,

    Everything seems to work fine, at least for now, not sure if I need to change all those files port from 8888 to 80? I guess I overwrote the default port from 8888 to 80.

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    @mridulgoswami and @sirlouen thank you both for your help.

    I first tried this:
    WP_ENV_PORT=3333 npx wp-env start
    It did not work and I had other issues

    But when I tried this it worked:
    WP_ENV_PORT=80 npx wp-env start

    Those two critical issues in site health have vanished.

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    @sirlouen
    First, I run:
    docker exec ad7119d7599006247378c85362dceba9-wordpress-1 php -r "require 'wp-load.php'; echo site_url();"
    I got:
    http://localhost:8888
    Then I run:
    docker exec ad7119d7599006247378c85362dceba9-wordpress-1 php -r 'require "wp-load.php"; echo get_option("siteurl");'
    I got this:
    http://localhost:8888

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    I want to add that the WordPress version: 6.8.2, the last stable release.

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    Hi @bsfherman, I did another design for the header without disabling the Flex Container. It worked :).

    I used a container made of two columns only.

    Thank you everyone.

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    @alexbosch and @bsfherman I disabled Flex container and it ended up removing the footer and the header altogether.

    I need some custom CSS. Do you have any idea how to fix this with CSS?

    Thank you

    Thread Starter Fakhri Azzouz

    (@fakhriaz)

    Hi @bsfherman,

    When I use my phone or developers tools on my desktop browser, I still get the issue even a friend of mine reported the same issue. Same issue in Google chrome or firefox.

    Please check the screenshot in this link.

    Hi,

    Open footer.php and using ctrl + f search for “Powered by WordPress” also search for the name of your theme.

    It is preferable to delete the whole div.

    An easier way is to use this plugin: https://en-gb.ww.wp.xz.cn/plugins/remove-footer-credit/

    Do not forget to back-up your site and create a copy of your footer.php file before editing it.

    Regards,

    Hi @steph413,

    Try this:

    1-Go to Appearance > Customize on the WordPress dashboard

    2-Click Additional CSS at the bottom of the menu

    3-Paste in the CSS code below

    .site-info { display: none; }

    Regards

    Forum: Everything else WordPress
    In reply to: Tags List

    Hi @saimon_86,

    Try this plugin: https://ww.wp.xz.cn/plugins/wp-import-export-lite/

    It is free and it also has only five stars reviews.

    All the best,

    Hi @logserval,

    1. Disable caching plugins
    2. Purge cache from browser
    3. Have you altered caching yourself in any way?
    4. If you’re using any CDN like Cloudflare, enable dev mode and purge cache from their side
    5. Refresh page with Ctrl+ F5(or Cmd + R for Mac) which ignores cache
    6. If you’re making changes in CSS or JS, for example, make sure to take a look at source code in dev panel – maybe your CSS selectors are just not superior or you’ve got an error in other code.

    7. after you update the page, are you sure you are checking the actual page and not just the preview version? The preview version just stuck to a specific change. Any later changes will not show up.

    If caching isn’t the problem, check these common mistakes with URLs and file names:

    1. Verify the URL – Make sure you’re entering the correct URL in your web browser.
    Double-check the full path and file names.
    2. Verify the template – If you’re editing a template, make sure the post or page
    you’re viewing in your browser is using the template you’re editing.
    3. Verify the file – If you are editing a file on your local computer and then
    uploading the updated version, make sure you uploaded the correct file. Also, make sure you’re not working with a file with a similar name or the same name in another folder.

    If none of that helps, it’s your host.

Viewing 15 replies - 1 through 15 (of 68 total)