ngrmm
-
Posts
421 -
Joined
-
Last visited
-
Days Won
3
Posts posted by ngrmm
-
-
thanks Jürgen.
no luck. still in english
i noticed that my html begins always like this:<html lang="en" …
is that a problem?
-
i did a multilanguage-install.
english and german are needed
i set german as default (install german languagepack at default)
then add english (en) as second language
my date-output is custom: %A %d %B %Y (Details Tab)
echo $page->datethe problem is that i always get the english ouput.
-
@teppo thanks
here the final code:
<div class="pagination"> <?php $prevPage = $page->prev; $nextPage = $page->next; if($page != $pages->get(1019)->children->first()) { echo "<a class='link next' href='" . $prevPage->url . "' >"; foreach($prevPage->image as $image) { $thumb = $image->height(60); echo "<div><img src='" . $thumb->url . "'/></div>"; } echo "<span>". $prevPage->title ."</span>"; echo "<span class='date' >". $prevPage->teaser_date ."</span>"; echo "</a>"; } if($page != $pages->get(1019)->children->last()) { echo "<a class='link prev' href='" . $prevPage->url . "' >"; foreach($nextPage->image as $image) { $thumb = $image->height(60); echo "<div><img src='" . $thumb->url . "'/></div>"; } echo "<span>". $nextPage->title ."</span>"; echo "<span class='date' >". $nextPage->teaser_date ."</span>"; echo "</a>"; } ?> </div>
-
thanks Marttijn
i edited the code but still getting Internal Error
there are always at least 3 children of that page (1019). and all of them aren't hidden.
<div class="pagination"> <?php $prevPage = $page->prev; $nextPage = $page->next; if($page != $pages->get(1019)->children->first()) { echo "<a class='link prev' href='" . $prevPage->url . "' >" foreach($prevPage->image as $image) { $thumb = $image->height(60); echo "<div><img src='" . $thumb->url . "'/></div>"; } echo "<span>". $prevPage->title ."</span>"; echo "<span class='date' >". $prevPage->teaser_date ."</span>"; echo "</a>" } if($page != $pages->get(1019)->children->last()) { echo "<a class='link next' href='" . $nextPage->url . "' >" foreach($nextPage->image as $image) { $thumb = $image->height(60); echo "<div><img src='" . $thumb->url . "'/></div>"; } echo "<span>". $nextPage->title ."</span>"; echo "<span class='date' >". $nextPage->teaser_date ."</span>"; echo "</a>" } ?> </div>
-
there is a pagination (next|prex) at the end of the page
i want to hide next on the last page of the siblings and hide prev on the first<?php if($page != $pages->get(1019)->children->first()) { echo "<a class='link prev' href="$page->prev->url">"; foreach($page->prev->image as $image) { $thumb = $image->height(60); echo "<div><img src='$thumb->url'/></div>"; } $test = $page->prev; echo "<span> $test->title </span>"; echo "<span class='date' > $test->teaser_date </span>"; } echo '</a>' if($page != $pages->get(1019)->children->last()) { echo "<a class='link next' href="$page->next->url">"; foreach($page->next->image as $image) { $thumb = $image->height(60); echo "<div><img src='$thumb->url'/></div>"; } $test = $page->next; echo "<span> $test->title </span>"; echo "<span class='date' > $test->teaser_date </span>"; } echo "</a>"; ?>
line 3: echo "<a class='link prev' href="$page->prev->url">"; is causing the error but i don't know why
-
i changed the order and it worked
if($box->text) {//text
}
else {
//images
}
would be nice to know why it doesn't work the other way around
-
thanks
but it doesn't work
i still get this
<div class="box images" >…</div> <div class="box images" >…</div> <div class="box images" >…</div> <!-- this one below ist the repeater without images --> <div class="box images" ></div>
-
i have a repeater with 2 fields
– image
– text
if there are images uploaded then the output should be only the image field.
if no images uploaded, then only the text-field should be shown
right now, if the image-field is empty and the text-field is filled. i'm getting two boxes. and the first one is empty.
<?php foreach($page->repeater as $box) { if($box->images) { ?> <div class="box images"> <?php foreach($box->images as $image) { echo "<img src='$image->url'/>"; } ?> </div> <?php } else { } if($box->text) { ?> <div class="box text"><?php echo $box->text; ?></div> <?php } } ?>
-
i've the same problem with 1und1
my password is just text without ' or "any ideas?
-
-
pages with the same template have a page-field. i can select multiple pages and they are like tags
i output them like this
<?php foreach($page->tag as $tags) { echo "<a href='$tags->url'>{$tags->title}</a>"; } ?>
the tag-pages ($tags->url) should just show the pages with the certain tag selected.
is there a way to filter?
where in the documentation do i find something about this.
-
i solved it with
$('p img').unwrap();
maybe someone knows a better solution
-
Date – Multilanguage Output
in Multi-Language Support
Posted
and i treid it with this in the template-file
utf8_encode(strftime('%d. %B %Y', $page->getUnformatted('date')));