PDA

View Full Version : IMAGE_NOTES doesn't show! (new one)


labo
03-18-2006, 11:41 AM
Hi all,

first 've used the search function and hve seen, that my problem is always known.

But if <IMAGE_NOTES> even doesn't work, there was always an older version of pixelpost. So I update my Version to 1.5b....

But equal what template I choose, notes will not be show....

Do you know what can be wrong?

I'm thankfull for every help!! Thanx!

Connie
03-18-2006, 12:02 PM
I know these are simple questions, but who knows:

do you use a template which uses <IMAGE_NOTES> at all?

did you enter image notes in the text-area for the images when you posted them?

is this part of the template visible or maybe defined in the same color as the background in the CSS?

I checked at my installation and it is shown in all templates where this tag is used and the note is entered when posting...

I ask these questions because I noticed so many simple reasons..

labo
03-18-2006, 12:45 PM
Well, I still installed the standard version and templates.

E.g.:

I want to use the template "simple". The Code for the Images is on "image_template.html":

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>
<title><SITE_TITLE></title>

<!-- META -->
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
<meta http-equiv="content-type" name="keywords" content="PhotoBlog,<SITE_TITLE>,<IMAGE_TITLE>,Pixelpost" />
<meta http-equiv="content-type" name="description" content="<SITE_TITLE>-PhotoBlog: <IMAGE_TITLE>, <IMAGE_NOTES_CLEAN>" />

<!-- CSS -->
<link rel="stylesheet" type="text/css" href="templates/simple/styles/light.css" title="light" />
<link rel="alternate stylesheet" type="text/css" href="templates/simple/styles/dark.css" title="dark" />

<!-- SCRIPTS -->
<script type="text/javascript" src="templates/simple/scripts/styleswitcher.js"></script>

</head>

<body>

<div id="navigation">
<h1>
<a href="index.php" title="Return to current image"><SITE_TITLE></a>
</h1>
<span class="menu">
<a href="index.php" title="Return to Homepage">Startseite</a> |
<a href="<SITE_BROWSELINK>" title="Browse">Katalog</a> |
<a href="index.php?x=about" title="About">&Uuml;ber mich</a>
</span>
</div>

<a href="index.php?showimage=<IMAGE_PREVIOUS_ID>">
<img src="images/<IMAGE_NAME>" alt="<IMAGE_TITLE>" title="<IMAGE_TITLE>" width="<IMAGE_WIDTH>" height="<IMAGE_HEIGHT>" id="photo" />
</a>

<div id="image-navigate">
<span class="image-previous"><IMAGE_PREVIOUS_LINK></span>
<span class="image-next"><IMAGE_NEXT_LINK></span>
</div>

<div id="image-info">
<span class="addcomment">+ <COMMENT_POPUP></span>
<span class="title"><IMAGE_TITLE></span> - <IMAGE_NOTE> <IMAGE_DATETIME><br>
<IMAGE_NOTES>
<table width="100%">
<tr>
<td id="image-notes">
<IMAGE_NOTES>
</td>
<td id="image-exif">
<EXIF_CAMERA_MODEL><br />
<EXIF_EXPOSURE_TIME><br />
<EXIF_APERTURE><br />
<EXIF_FLASH><br />
</td>
</tr>
</table>
</div>


<div id="footer">
Seiten-Style: <a href="#" onclick="setActiveStyleSheet('light'); return false;">Hell</a> /
<a href="#" onclick="setActiveStyleSheet('dark'); return false;">Dunkel</a>&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;<SITE_RSS_LINK> / <SITE_ATOM_LINK>&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;&nbsp;
<a href="http://validator.w3.org/check/referer" title="This website uses Valid xHTML">Valid xHTML</a> / <a href="http://jigsaw.w3.org/css-validator/check/referer" title="This website uses Valid CSS2">Valid CSS</a>
</div>

</body>
</html>

And if I use this template (or even other one).... the notes will not be display)...!?!?!?!

I don't know what's wrong.

PS: I put a describtion to every image. that can't be the mistake.... :-)

labo
03-18-2006, 12:55 PM
My problem is also on "pepper_revisited"... :(

Connie
03-18-2006, 01:58 PM
as I do not know the code of pepper-revisited I could only check your page with simple-template. but unfortunately that is not activated...

when I use <IMAGE_NOTES> it is working ;=(

labo
03-18-2006, 02:29 PM
i've deleted all - an d install everything new but just version 1.5b - and now it works!

thanks a lot for helping me.

Connie
03-18-2006, 02:40 PM
great, I am glad..

sometimes just some files are not updated.. and if it were me, I just would erase everything and install new

but to recommend that in a support forum could be politically difficult ;=)

but now one more satisfied user of 1.5 here, I hope!

shaped.ch
04-16-2006, 09:03 PM
ok... i've tracked down this problem.
the function markdown() (in includes/markdown.php) does not really work.

system setup:
Linux middleearth 2.4.27-2-386 #1 Wed Aug 17 09:33:35 UTC 2005 i686 GNU/Linux (debian sarge/stable)
PHP 5.1.2-1.dotdeb.2 (cli) (built: Jan 31 2006 01:31:38)
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
PixelPost v1.4.3

i had not the time to fix the code. sorry. its probably a php v5.1.2 problem.
but you can comment out the functions which are not working in includes/markdown.php.

WARNING: commenting out functions is just a workaround. I don't know if there are sideeffects! - You have to know what you are doing. As i don't think you'll get support if you've a hacked pixelpost installation!

here's a diff patch for fixing your markdown.php

--- markdown.php.ori 2006-04-16 22:40:51.000000000 +0200
+++ markdown.php.edited 2006-04-16 22:43:02.000000000 +0200
@@ -152,7 +152,7 @@
$text = preg_replace('/^[ \t]+$/m', '', $text);

# Turn block-level HTML blocks into hash entries
- $text = _HashHTMLBlocks($text);
+ // $text = _HashHTMLBlocks($text);

# Strip link definitions, store in hashes.
$text = _StripLinkDefinitions($text);
@@ -218,7 +218,7 @@
'script|noscript|form|fieldset|iframe|math|ins|del ';
$block_tags_b = 'p|div|h[1-6]|blockquote|pre|table|dl|ol|ul|'.
'script|noscript|form|fieldset|iframe|math';
-
+
# First, look for nested blocks, e.g.:
# <div>
# <div>
@@ -302,18 +302,19 @@
$text = _DoHeaders($text);

# Do Horizontal Rules:
- $text = preg_replace(
+ /* $text = preg_replace(
array('/^( ?\* ?){3,}$/m',
'/^( ?- ?){3,}$/m',
'/^( ?_ ?){3,}$/m'),
"\n<hr$md_empty_element_suffix\n",
$text);
-
+
$text = _DoLists($text);

$text = _DoCodeBlocks($text);

$text = _DoBlockQuotes($text);
+ */

# Make links out of things like `<http://example.com/>`
$text = _DoAutoLinks($text);
@@ -322,9 +323,9 @@
# was to escape raw HTML in the original Markdown source. This time,
# we're escaping the markup we've just created, so that we don't wrap
# <p> tags around block-level tags.
- $text = _HashHTMLBlocks($text);
+ // $text = _HashHTMLBlocks($text);

- $text = _FormParagraphs($text);
+ // $text = _FormParagraphs($text);

return $text;
}


btw. you could also edit your index.php to cut out the function markdown();

--- index.php.ori 2006-04-16 23:10:52.000000000 +0200
+++ index.php 2006-04-16 23:09:51.000000000 +0200
@@ -153,7 +153,7 @@
$image_date_year = substr($row['datetime'],2,2);
$image_date_month = substr($row['datetime'],5,2);
$image_date_day = substr($row['datetime'],8,2);
-$image_notes = markdown(pullout($row['body']));
+$image_notes = pullout($row['body']);
$thumbnail_extra = getimagesize("thumbnails/thumb_$image_name");
$image_extra = getimagesize("images/$image_name");
$image_width = $image_extra['0'];