PopUp-Window Replacement Tag

Post custom hacks and enhancements for phpwcms here only. Maybe some of these things will be included in official release later.
Post Reply
pixelpeter
Posts: 45
Joined: Fri 27. Feb 2004, 16:00

PopUp-Window Replacement Tag

Post by pixelpeter »

With this replacement tag you're able to open an article in a new popup window. If you want to you can also specify the width and height of the new window.

Usage this tage like this:

[POPUP:IDorAlias]LinkName[/POPUP]

or

[POPUP:IDorAlias:Width:Height]LinkName[/POPUP]

Read more here and see it in action
http://phpwcms.pixelpeter.de/index.php?popupwindow
User avatar
nekket
Posts: 613
Joined: Tue 18. Nov 2003, 15:46
Location: Baden-Baden
Contact:

Post by nekket »

Hello pixelpeter,

tried to use your popup mod... it works and opens the page but only the index.php and not the alias or ID... do you know why?
pixelpeter
Posts: 45
Joined: Fri 27. Feb 2004, 16:00

Post by pixelpeter »

There's actually a "feature" on some systems (didn't evaluate it deeper) causing this not to work by using the php-function is_int :cry:

- In front.func.inc.php search for the function get_article_jslink
- Search the line "if( is_int($article_id) )"
- and replace it with "if( is_numeric($article_id) )"

Maybe this helps !!

This doesn't change the behavior for aliases: Please try using simple aliases containing only a-z and test if this solves the problem.
bachi
Posts: 308
Joined: Fri 6. Aug 2004, 17:52
Location: Western Styria, AUSTRIA
Contact:

Post by bachi »

ich hab das tool jetzt eingebaut, aber er zeigt mir folgenden Fehler:

Code: Select all

Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /home/www/web57/html/include/inc_front/front.func.inc.php on line 1756
was könnte da der fehler sein??
Carino
Posts: 98
Joined: Sat 25. Sep 2004, 13:27
Location: NRW - Oberbergisches Land
Contact:

Post by Carino »

Einen Fehler bekomme ich zwar, nicht, aber es öffnet sich nicht alleine der Artikel, sondern die ganze seite mit dem artikel als popup. eigentlich logisch. aber interessanter wäre ein tag mit dem man externe seiten einbinden kann.

ich helfe mir z.b. hiermit:
<a href="#" onClick="window.open('quiz.php', 'NewWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,copyhistory=no,width=250,
height=340')">Quiz</a>

wäre das nicht eine Idee für einen neuen Tag?
User avatar
isac
Posts: 410
Joined: Tue 18. Nov 2003, 13:13
Location: Portugal
Contact:

Post by isac »

Old post this one!!

It's possible popup not the entire page but only desired content part?
POR :D TUGAL
st3fek
Posts: 17
Joined: Thu 4. Aug 2005, 11:17
Location: Poland, Sosnowiec
Contact:

Post by st3fek »

pixelpeter, nice mod - thx. :) I'll try to modificate it a little bit, to get only article in a different template layout than it was declared on structure.
BTW. you don't have to modificate these two files to get it work. Just put the code into phpwcms_template/inc_script/frontend_render/ and for example popup_window.php - it should work fine. :)
Post Reply