0

I am developing a theme and it currently has no theme information. Right now it is pulling it's name from the theme folders name and the "Author"is anonymous.

I tried changing it by adding code into the style.css as such:

/*
Theme Name: Twenty Twelve
Theme URI: http://wordpress.org/extend/themes/twentytwelve
Author: the WordPress team
Author URI: http://wordpress.org/
Description: The 2012 theme for WordPress is a fully responsive theme that looks great on any device. Features include a front page template with its own widgets, an optional display font, styling for post formats on both index and single views, and an optional no-sidebar page template. Make it yours with a custom menu, header image, and background.
Version: 1.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: light, gray, white, one-column, two-columns, right-sidebar, flexible-width, custom-background, custom-header, custom-menu, editor-style, featured-images, flexible-header, full-width-template, microformats, post-formats, rtl-language-support, sticky-post, theme-options, translation-ready
Text Domain: twentytwelve

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool, have fun, and share what you've learned with others.
*/

It succeeds at adding text into the author name, except it adds it all with the formatting messed up. It looks like this on my theme page:

Current Theme
Twenty TwelveTheme URI: http://wordpress.org/extend/themes/twentytwelveAuthor: the WordPress teamAuthor URI: http://wordpress.org/Description: The 2012 theme for WordPress is a fully responsive theme that looks great on any device. Features include a front page template with its own widgets, an optional display font, styling for post formats on both index and single views, and an optional no-sidebar page template. Make it yours with a custom menu, header image, and background.Version: 1.1License: GNU General Public License v2 or laterLicense URI: http://www.gnu.org/licenses/gpl-2.0.htmlTags: light, gray, white, one-column, two-columns, right-sidebar, flexible-width, custom-background, custom-header, custom-menu, editor-style, featured-images, flexible-header, full-width-template, microformats, post-formats, rtl-language-support, sticky-post, theme-options, translation-readyText Domain: twentytwelveThis theme, like WordPress, is licensed under the GPL.Use it to make something cool, have fun, and share what you've learned with others.

By Anonymous Version
Customize OPTIONS: Widgets Menus Customize

So basically what it is doing is adding all of the theme information into the Author description/heading, instead of adding the info into it's own correct description/heading. Can anyone tell me why this could possibly be happening? I haven't found anything at all about this issue, and I am baffled as to why it would even happen.

2
  • 1
    Cannot reproduce. Putting your header in a blank style.css and creating a blank index.php, the theme shows correctly. Btw, why would you create a theme called TwentyTwelve?
    – brasofilo
    Commented Oct 7, 2013 at 6:01
  • @brasofilo I can't tell if you are joking or not. I was using that as an example and took it from the twenty twelve theme. Commented Oct 7, 2013 at 17:24

1 Answer 1

1

From what you are describing, the ASCII is being incorrectly converted when you upload the file via FTP.

Go to WP-Admin and select Appearance -> Editor. Look at Style.css, does it look like it's been minified in a really strange way? If so, you have a problem with the UTF encoding on your end. It'll get a lot nastier if this happens to a core file like single.php.

In Filezilla, change your transfer type to "Binary", re-upload, and see what happens.

2
  • You had it spot on! I have been using notepad++ to edit files and it was showing up fine. Then downloaded a new copy with the transfer type set to binary, modified the broken text and then re-uploaded it and it is working fine. Is this an issue with notepad ++ or just because filezilla was set to "ASCII" in transfer type? Commented Oct 7, 2013 at 13:27
  • The same thing happens to me out of JetBrains PHPStorm. I'm not sure what the mixup is but once the file is properly transferred, it seems to go back to normal on autopilot from then o,n after you download the server version back to local. This made me nuts for months before I figured it out. Commented Oct 7, 2013 at 18:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.