AlbumCustomData render issue

When I use `<?php echo AlbumCustomData(); ?>` it shows up, but the data that I've entered doesn't line break where I've done so on the administrative end.

Example, if place this data in the custom data field:

Some information
More stuff
ZenPhoto rocks


It renders like this:

Some informationMore stuffZenPhoto rocks

Any Suggestions?

Comments

  • acrylian Administrator, Developer
    You have use html tags like `
    ` or `

    ` if you want a line break.
  • csx Member
    I was hoping to avoid html in the admin fields (this will eventually be used by someone not so html-savy).

    Why does the Description field (`<?php printAlbumDesc(); ?>`) render with line breaks where the custom data field doesn't? I looked in the mySQL structure, but could not find a difference between the two (both setup as 'text'). Does telling something to "print" versus "echo" make the difference?
  • acrylian Administrator, Developer
    Well, using is not that difficult even for a none html savy person...

    The function `printAlbumDesc()` is setup to replace invisible line breaks with `
    ` when printed (`echo getAlbumDesc()` would not do that). Since we don't have a `printAlbumCustomData()` function I guess we could add that to do the same.
  • csx Member
    That would be great! Will that by any chance be available in an upcoming nightly build?
  • acrylian Administrator, Developer
    Yep, will be in tonight's nightly.
  • csx Member
    Thank you! That's awesome!
  • csx Member
    Acrylian, any chance you can tell me what specific file(s) I'd need to update? I've made a few custom changes to non-theme files (ie: functions.php) and want to make sure I don't lose anything.

    Thanks again.
  • It is NEVER recommended that you update only some files as there may be multiple dependencies. Best you use a file comparison program to see what has changed. Better still is not to modify the zenphoto core files. Usually using theme based custom functions can handle whatever you need. (The first implementation of subalbum image paging was done as a custom function, so I imagine pretty much anything could be done this way.)
  • csx Member
    Thanks for the heads up, I'll just pull what I changed and place it back in later. You guys do great work.
Sign In or Register to comment.