WordPress.org

Ready to get started?Download WordPress

Forums

After Install, weird ASCII code on homepage (12 posts)

  1. gbm
    Member
    Posted 5 years ago #

    I am installing WordPress for the 1st time on
    http://www.greenbronxmachine.com
    and I tried to install but I get weird ASCII code on my homepage
    Please help thanks

  2. WebDev WaxLotus LLC
    Member
    Posted 5 years ago #

    Yuck.

    Is that from the default theme? Did you get that WP zip file from here?
    Is this a *nix server or windows?

    Have you tried ftp'ing all the files over again?

    I noticed this: Copyright 2007 Apple Inc., all rights reserved

    and mention of this wp-blog-header.php

    Not saying that this is your problem, but:

    http://vidmar.net/weblog/archive/2007/07/29/WordPress-error-quotFailed-opening-required-.wp-blog-header.phpquot.aspx

    I would delete that file on the server, and re-ftp a cherry version from the zip again.

  3. gbm
    Member
    Posted 5 years ago #

    I simply downloaded the WordPress from website
    I am using a Mac and
    had to write the config.php in Microsoft Word because
    TextEdit wouldn't let me save as PHP

    and here is the code of what my PHP has in it
    which is named wp-config.PHP

    define('DB_NAME', 'greenbronxmachine.com'); // The name of the database
    define('DB_USER', 'PostDesktop'); // Your MySQL username
    define('DB_PASSWORD', 'Web1234'); // ...and password
    define('DB_HOST', 'localhost'); // 99% chance you won't need to change this value

    thanks

  4. WebDev WaxLotus LLC
    Member
    Posted 5 years ago #

    Yikes! Is that the real info? If so: RED ALERT! You've grabbed your ankles buddy...

    Do the following immediately:

    In your wp-config.php file, change the values of

    define('DB_NAME', 'greenbronxmachine.com'); // The name of the database
    define('DB_USER', 'PostDesktop'); // Your MySQL username
    define('DB_PASSWORD', 'Web1234'); // ...and password

    which means you have to change the values on your server as well!

    No sharing the secret connection information with the world!

  5. WebDev WaxLotus LLC
    Member
    Posted 5 years ago #

    Ok, the orginal problem was most likely caused by you using MS Word to edit a text file. MS Word places all sorts of invisible garbage in every file it touches because that's how they roll. They want to make it easy for you to stay on the reservation...

    Grrr.

    To edit files like .php you can use MS Notepad but never MS Word. When you save the file, make sure it ends in .php and not .php.txt or .txt.php
    Oh wait, you said Mac, TextEdit something something.

    http://macromates.com/
    http://www.barebones.com/products/textwrangler/
    http://www.pure-mac.com/webed.html

  6. gbm
    Member
    Posted 5 years ago #

    hey thanks will change password and username after i straighten out
    for security, but i am such a newbie that i am not following your advice totally,
    when you say change the info on the server i'm not sure how to do that
    in my CPanel in Godaddy? (my iSP) and TExtEdit did not let me save as PHP file
    so i will try the other freebies you put thanks
    still need to get a handle on how to simply complete installation
    i am very used to Dreamweaver taking care of everything for me behind the scenes so
    it's time i get used to these here WP Waters :)

  7. s_ha_dum
    Member
    Posted 5 years ago #

    Yikes! Is that the real info? If so: RED ALERT! You've grabbed your ankles buddy...

    Oh God that's funny!!!

    gbm: Its ok if you save as .txt-- just change the ending to .php after you save. That said, I can't figure out why you can't save as .php. Textedit will save as PHP for me. Just type the .php as part of the filename. You want to make sure you aren't saving as Rich Text though. That setting is set in Textedit->Preferences on my copy but Apple changes everything with every minimal version change so who knows where it is on your system. You also want to make sure you aren't saving with Mac line endings.

  8. s_ha_dum
    Member
    Posted 5 years ago #

    Wow. I didn't realize that http://www.greenbronxmachine.com is actually echoing the config values to the world. Get that fixed quick.

  9. gbm
    Member
    Posted 5 years ago #

    a newbie question, but why is it not good to have config files echoed? hacking i take it...yeah i just deleted everything from server, so in terms of config values, do i need to change username and password for next try and I am using TextWrangler on Mac which saves to PHP correctly but it still didn't work (it put less code on homepage) so i am not sure if this is WordPress issue or a MYSQL issue on my Godaddy server, do i need to configure anything in there too? thanks, newbie

  10. s_ha_dum
    Member
    Posted 5 years ago #

    Yes, hacking is the problem. Echoing the DB values is like giving a world full of ne'er-do-wells the keys to your car, your house, your office, and your liquor cabinet. Its kinda bad.

    Re-upload everything but do it directory by directory. Don't try to upload in one fell swoop. FTP can choke and files won't upload properly. That incomplete upload might be your problem.

    I can't stress enough how important it is to save your wp-config with *NIX line endings. Mac line ending will frell PHP/html in a big way. I don't know if TextWrangler saves with Mac line endings or not. You'll have to dig around and find out.

  11. gbm
    Member
    Posted 5 years ago #

    what is *NIX line endings?
    is that literally how lines should end?
    thanks will try directory by directory too

  12. s_ha_dum
    Member
    Posted 5 years ago #

    Yeah, it is literally how lines end, but you can't see them under most circumstances. They are hidden control characters.

Topic Closed

This topic has been closed to new replies.

About this Topic