WCMSBlog v0.6 (was Phpwcms Blog Module)

Post custom hacks and enhancements for phpwcms here only. Maybe some of these things will be included in official release later.
nehemia
Posts: 118
Joined: Mon 11. Sep 2006, 21:19
Location: Fürth
Contact:

Post by nehemia »

Hallo munzli,

vielen Dank für Deine Nachricht. Ich habe jetzt den Code:

Code: Select all

<?php
print_r(system('locale -a'));
?>
wie Du gesagt hast in einem Editor kopiert, als munzli.php abgespeichert und sie in das ROOT-Verzeichnis meines Servers kopiert. Wenn Du also
http://mg888.ohost.de/munzli.php
aufrufst, müsstest Du die Meldung sehen können. Es ist leider eine Fehlermeldung!

Gruß,
Martin
munzli
Posts: 20
Joined: Wed 25. Oct 2006, 19:04
Location: Zürich, Switzerland
Contact:

Post by munzli »

dein host hat das abgeschaltet... gibt's keine möglichkeit ein shell befehl auszuführen? die ausgabe von 'locale -a' würde mich interessieren. frag sonst mal dein hosting...

wie gesagt hast du noch ein fehler im blog.module.php

blogcommentheader ist falsch und der code müsste so aussehen (ca. bei 150)

Code: Select all

if ($ccount > 0)

			{

				$s .= "<div class='blogcomments'>";

				while ($comment = mysql_fetch_array($cres))

				{

					$s .= "<div class='blogcommentheader'><b>";

					if ($comment ["url"] != "http://" && $comment["url"] != "") {
						$s .= "<a href='" . $comment["url"] . "'>";
					}

					$s .= $comment["author"];

			 		if ($comment ["url"] != "") {
						$s .= "</a>";
					}

					$s .= ":</b></div><br />";

					$s .= nl2br(trim($comment["comment"]));

					$s .= "<div style='height: 1px; border-top: 1px dashed #000; width: 100%; padding: 0; margin: 6px 0 6px 0;'></div>";

				}

				$s .= "</div>";

			}
danach sollte nur der titel eingefärbt sein.
nehemia
Posts: 118
Joined: Mon 11. Sep 2006, 21:19
Location: Fürth
Contact:

Post by nehemia »

Vielen Dank, munzli,
also der Codeaustasuch hat einen Teilerfolg gebracht. Jetzt ist allerdings der Doppelpunkt im Blogcommentheader andersfarbig als der Blogkommentar-Name. Und die sollten eigentlich schon gleich sein.

Und was mich auch irritiert ist, dass es eine Fehlermeldung gibt, wenn man sich im Menü "Alle" anzeigen läßt, dann erscheint mitten in der Abfolge der Auflistung der Blogs ein Hinweis "ZURÜCK", das nicht richtig dargestellt wird, da die dazugehörigen "<<" Pfeile anderswo (oben rechts) angezeigt werden als dort. Klickt man jetzt drauf, kommt eine Fehlermeldung. Außerdem erscheint dann in der Auflistung unten "WEITER >> WEITER>> WEITER>>"...

Das mit dem locale will ich noch mit dem Hoster versuchen zu klären.
Gruß,
Martin
munzli
Posts: 20
Joined: Wed 25. Oct 2006, 19:04
Location: Zürich, Switzerland
Contact:

Post by munzli »

der blog kommentar name ist als link natürlich ander farbig als die ohne link... wenn du alle gleich willst musst du

Code: Select all

.blogcommentheader a, .blogcommentheader a:link, .blogcommentheader a:visited
{
     color: #ff0000;
}
setzen und für ein hover auch noch:

Code: Select all

.blogcommentheader a:hover, .blogcommentheader a:active, .blogcommentheader a:focus
{
     color: #0000ff;
}
(farben natürlich so wies du möchtest)


das mit dem << oben ist halt weil die zeichen noch platz haben da... wenn du dein blogtext von width:510px; auf width:525px; setzt wirds unten angezeigt weils kein platz mehr hat... ja man könnte es noch einer class zuordnen aber das brauch ich in meinem layout nicht...


und das weiter weiter weiter kommt daher das du alle 3 blogs in einer seite darstellst... und mit klick auf zurück wird per $_GET der offset bestummen, alle drei blogs haben dann die anzeige weil sie alle das offset berücksichtigen... darum ist es keine gute idee alle 3 blogs untereinander anzuzeigen[/code]
nehemia
Posts: 118
Joined: Mon 11. Sep 2006, 21:19
Location: Fürth
Contact:

Post by nehemia »

Also was die locale-Einstellung anbelangt, habe ich mich mittlerweile schlau gemacht: Die system() Einstellung ist auf meinem Server wohl ausgeschaltet. Ich habe im entsprechenden Forum nachgehakt und folgender Vorschlag wurde auf meine Frage gemacht, ob man die system()-Einstellung ermöglichen kann:
Muss das denn auf diese Art und Weise sein? Kannst du nicht einfach ein Array nehmen, in dem du alle Namen hinein schreibst und dann einfach den richtigen herauspickst?

Also ungefähr so:

Code:
<?php
$wochentage = Array("Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag");
echo $wochentage[date("w")];
?>
Keine Ahnung, ob das möglich ist bzw. was ich da jetzt genau machen muss. Kann jemand was dazu sagen?
Gruß, Martin
munzli
Posts: 20
Joined: Wed 25. Oct 2006, 19:04
Location: Zürich, Switzerland
Contact:

Post by munzli »

nehemia wrote: Also ungefähr so:

Code:

Code: Select all

<?php
$wochentage = Array("Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag");
echo $wochentage[date("w")];
?>
Keine Ahnung, ob das möglich ist bzw. was ich da jetzt genau machen muss. Kann jemand was dazu sagen?
Gruß, Martin
yep so würde das auch gehen aber ich würde lieber wissen wie deine locales heissen und es dan korrekt per setlocale machen... da müsstest du dein ISP fragen...

wegen dem script, einfach einbauen dort wo die ausgabe geschiet, also anstatt

Code: Select all

$s .= "<span class='blogdate'>" . strftime("%a %d/%m/%y %H:%M", $e["time"]) . "</span>";
irgendwie sowas:

Code: Select all

$wochentage = Array("Sonntag","Montag","Dienstag","Mittwoch","Donnerstag","Freitag","Samstag"); 
$s .= "<span class='blogdate'>" . $wochentage[strftime("%w", $e["time"])] . ',&nbsp;' . strftime("%d/%m/%y %H:%M", $e["time"]) . "</span>";
oder so ähnlich... meine ungetestete 2 minuten lösung ;)
nehemia
Posts: 118
Joined: Mon 11. Sep 2006, 21:19
Location: Fürth
Contact:

Einbau Weblog in phpwcms135pre070919

Post by nehemia »

Hallo munzli,
nachdem es mir ja gelungen ist den Weblog unter phpwcms 1.3.5pre vom 20.08.07 zu installieren, habe ich versucht, den Weblog auch unter phpwcms 1.3.5pre vom 19.09.07 zu installieren. Dies scheint leider nicht ohne Komplikationen möglich zu sein, da im Backend nun folgender Fehler auftritt:

Im Menü Module erscheint "Blog" zweimal untereinander.

Weißt Du Rat, wie man das beheben kann?
Gruß,
Martin
nehemia
Posts: 118
Joined: Mon 11. Sep 2006, 21:19
Location: Fürth
Contact:

[SOLVED]Einbau Weblog in phpwcms135pre070919

Post by nehemia »

Habe mittlerweile das Problem lösen können! Hatte aus Versehen in der Datei phpwcms.php eine Zeile doppelt stehen (vermutlich durch das reinkopieren!). Der Doppelteintrag für Blogs im Menü Module ist weg. Installation des phpwcms_weblogs ist also auch unter der neuen Version 1.3.5pre vom 19.09.07 ganz normal möglich.
Gruß,
Martin
memphis
Posts: 4
Joined: Sat 25. Mar 2006, 12:48
Location: Halstenbek
Contact:

Re: WCMSBlog v0.6 (was Phpwcms Blog Module)

Post by memphis »

Hallo,
ich bin auch grade dabei, das Blogmodul zum laufen zu bekommen und scheitere daran seit einiger Zeit...
Der entsprechende Link wird bei mir im Backend angezeigt, aber wenn ich darauf klicke habe ich dort wo eigentlich der Inhalt zu sehen sein soll eine leere Fläche.

Ich habe diese Anleitung:
http://www.shinypixel.co.uk/files/wcmsb ... nstall.pdf
und
http://www.munz.li/?p=24

ausprobiert. Leider beide mit dem selben Ergebnis...
Ich setze die Version 1.3.9. ein...

Kann mir vielleicht jemand helfen? Bei bedarf richte ich auch entsprechende Zugänge ein...
always remember:
amateurs built the ark
and professionals built the titanic
______________________________________
http://www.andreasgrotevent.de
http://www.xwsnet.de
http://www.thefillingviolets.de
User avatar
juergen
Moderator
Posts: 4556
Joined: Mon 10. Jan 2005, 18:10
Location: Weinheim
Contact:

Re: WCMSBlog v0.6 (was Phpwcms Blog Module)

Post by juergen »

Das kann nicht funktionieren... nimm das etwas neuere Modul http://forum.phpwcms.org/viewtopic.php?f=8&t=16033, das kopierst du in den Modul Bereich, erstellst die Datenbanken und morgen kannst du dien system updaten ohne etwas zu verändern..
memphis
Posts: 4
Joined: Sat 25. Mar 2006, 12:48
Location: Halstenbek
Contact:

Re: WCMSBlog v0.6 (was Phpwcms Blog Module)

Post by memphis »

AHHHHHH.....
Danke

Das klappt ja wunderbar... So soll das sein. Schön angenehm. :-)

Eine Frage noch.
Wie baue ich das in meine Seite/n ein?

Ok, hat sich erledigt... Genauso, wie bei dem "alten" mit dem Replacement-Tag.

Danke nochmal...
always remember:
amateurs built the ark
and professionals built the titanic
______________________________________
http://www.andreasgrotevent.de
http://www.xwsnet.de
http://www.thefillingviolets.de
nebenaube
Posts: 139
Joined: Fri 23. Nov 2007, 20:39
Location: Redlands, CA
Contact:

Re: WCMSBlog v0.6 (was Phpwcms Blog Module)

Post by nebenaube »

Hi, I'm working with 1.3.9 and the hack-free version of shiny's blog based off of the code in wcmsblog05.zip (available at http://www.store66.de/WCMSBLOG.phtml).

I have made a number of code fixes and improved the mulit-language feature. I'm still having a hard time with IE 6 rendering the blog and crashing when I click a blog link like add comment or permalink (when displayed) it seems whatever is the last link in the div class 'right' breaks IE, crashing hard...

works perfectly in Firefox 3: http://www.eenac.com/index.php?eenac-blogs not so much with IE. The html and css code validate without errors.

Based on the testing I have done, the defect seems to be CSS related more so than the something in the javascript.
Anybody have any ideas?

(before anyone says it... no the guestbooks/comments content part are not what I want to use)
nebenaube
Posts: 139
Joined: Fri 23. Nov 2007, 20:39
Location: Redlands, CA
Contact:

Re: WCMSBlog v0.6 (was Phpwcms Blog Module)

Post by nebenaube »

hey everyone... I changed the css code to munzli's css code and my problem is solved.
munzli wrote:wie gesagt hab ich ein paar änderungen gemacht... musst halt selbst das css bearbeiten... firebug ist ein geniales add-on für das!

hier kannst du sonst mein teil des css das ich geschrieben habe mal anschauen:

Code: Select all

.blogcommentheader, 
.blogcontent, 
.blogcomments, 
.blogheader
{
	clear: both;
	display: block;
}

.blogtext
{
	float: left;
	width: 510px;
	padding: 10px;
	margin-bottom: 10px;
}

.blogcontent a, 
.blogcontent a:visited, 
.blogcontent a:link
{
	color: #000;
	background-color: #fff;
	text-decoration: none;
}
.blogcontent a:hover,
.blogcontent a:focus,
.blogcontent a:active
{
	color: #fff;
	background-color: #000;
}


.blogdate
{
	float: right;
	color: #666;
	font-size: 6pt;
}

.blogheadline
{
	background-color: #000;
	display: inline;
	font-size: 10pt;
	color: #fff;
	font-weight: bold;
	padding: 2pt;
}

.blogcomments .right
{
	float: right;
}

.blogheader
{
	margin-bottom: 10px;
}

.addblogcomment input, 
.addblogcomment textarea
{
	width: 350px;
	border: solid 1px #333;
	background-color: #ddd;
}

.gbInputFieldCaptcha
{
	width: 50px !important;
	margin: 6px 0px 11px 0px;
}

.addblogcomment label
{
	display: block;
}

.addblogcomment p
{

}

.addblogcomment, 
.comments
{
	margin-top: 7px;
	padding: 0px 0px 7px 0px;
	border-top: dashed 1px #000;
}

.blogcomments a, 
.blogcomments a:visited, 
.blogcomments a:link
{
	color: #353535;
	background-color: none;
	text-decoration: none;
}
.blogcomments a:hover,
.blogcomments a:active,
.blogcomments a:focus
{
	text-decoration: underline;
}
die seite werde ich posten sobald ich fertig bin ;)



der effekt kannst du noch bearbeiten im blog.modul.php

duration: 1000, transition: Fx.Transitions.Expo.easeOut
ist jetzt eingestellt.... du kannst auf der mootools seite mal schauen und z.B.
duration: 1500, transition: Fx.Transitions.Elastic.easeOut
einfügen
Post Reply