Search code examples
wordpressxampp

Critical error when installing wordpress in xampp


I have installed xampp in Windows 11. I started Apache and MySQL. I have download wordpress inside htdocs, unzip and renamed ¨ideas¨. I created a database in Mysql named ¨ideas¨. I open in the browset localhost/ideas it starts the wordpress asking me the country, the a form where I put database name ¨ideas¨, username ¨root¨, password empty and prefix of table ¨wp_¨, when I summit the form I get a critical error and I cannot continue with the wordpress setup.


Solution

  • UPDATED

    Will I tried And YAY!! therefor see the solution that i come with:

    1- Go to Download WordPress from HERE!!!!!! then under On my computer select win/mac/Linux then go down and download the one that work with your operating system.


    2- Then install It's simple
    Noties: WordPress will install phpmyadmin and Apache, therefor it will not need Xampp. It's a stand alone


    3- copy the wordpress files from the installation

    C:\Bitnami\wordpress-5.8.3-0\apps\wordpress\htdocs
    To
    C:\xampp\htdocs\wordpress

    and then edit the wp-config.php in xampp copied wordpress.

    in the wp-config.php

    /** The name of the database for WordPress */
    define( 'DB_NAME', 'bitnami_wordpress' );
    
    /** MySQL database username */
    define( 'DB_USER', 'bn_wordpress' );
    
    /** MySQL database password */
    define( 'DB_PASSWORD', 'Go_Hacker_Nothing_to_see_here XD' );
    
    /** MySQL hostname */
    define( 'DB_HOST', 'localhost' );
    
    /** Database charset to use in creating database tables. */
    define( 'DB_CHARSET', 'utf8' );
    
    /** The database collate type. Don't change this if in doubt. */
    define( 'DB_COLLATE', '' );
    

    save it.


    -4 edit the User's and the GRANT in the xampp phpMyAdmin Login then go to DB called phpmyadmin => PRIVILEGES => new User
    PRIVILEGES

    add the user you saw in define( 'DB_USER', 'bn_wordpress' ); and then add the same paswoord you putted in wp-config.php => Go_Hacker_Nothing_to_see_here XD


    5- go to wordpress phpmyadmin, for me it was http://127.0.0.1:81/phpmyadmin/
    Login as root + the password that you set on wordpress installation.
    Go to Database bitnami_wordpress then export as .sql then go. export
    6- go to xampp phpmyadmin Login as root or whatever then add new Database and call it as same as in the wp-config.php define( 'DB_NAME', 'bitnami_wordpress' );
    With this database selected go to import "Next to export" and select the .sql file from your downloads folder.


    -7 edit the port in table= wp_options for home and siteurl or just put them as http://localhost/wordpress/


    8- with the bitnami_wordpress database selected go to PRIVILEGES then the wordpress user that you created select edit-PRIVILEGES then go to Database next to global and select the database you created for wordpress and press go. then select all and go.

    edit-PRIVILEGES

    enter image description here


    9- in the wp-config.php edit this

    define('WP_TEMP_DIR', 'C:\Bitnami\wordpress-5.8.3-0/apps/wordpress/tmp');
    To
    define('WP_TEMP_DIR', 'C:\xampp\htdocs\wordpress\temp');

    Dont forget to create the file there
    10- Go To http://localhost/wordpress/wp-admin Login with the setup username and password, and delete all post in there!
    11- Go to sittings then permalink and set Common Settings to Plain


    **BTW:**WordPress Can Not be Installed With Xampp higher than 8.0.14
    So if you want it to be with xampp Download 8.0.14 and then do what you did in your question. If you dont want to do all 11 steps.


    BTW: you can uninstall wordpress we dont need it anymore
    If you want to ask why all of that!!. i will till you because the MySQL server from the wordpress instalation is extremly slow and you dont want to run 2 port and 2 MySQL


    Let me know what you got :)