Hi,
i'm back in this post with a solution.
the solution is here, it was posted by Vincent in drupalfr.org.
For non frensh speakers, i will try to explain how to to that:
-we must to add a variable to the link for the page that we want to load in the pop-up, example : http://mysite.com/node/18&pop=TRUE
-After , we must to add this portion of code in the template.php file in the theme folder:
-After we must to duplicate the file page.tpl.php, the new file will have page-popup.tpl.php as a name, then we can customize the new template file as we want in order to delete header, footer...
that's all, and sorry for my English
A simpler solution is to call-up your node via 'node/1234/popup'. Drupal would automatically use the template 'page-node-popup.tpl.php', if exists. No need to write a function.
Yeah, this is what I did, thanks. Now I can theme my popup, teach non-techies how to make a popup, and use the FCKEditor popup facilities in combination with this. Nice.
I've implemented the changes as suggested above and I can change the layout of the target page but it does not open up in a popup window. Instead it insists on opening in the original window... By the way, where's the code that actually creates the popup?
You need to add the html attribute "target" = "_blank". The way to add this depends on what's rendering your link. If, for example, you are using l(), then you'd want something like ...
Comments
have you tried using the
have you tried using the load_node function inside a piece of pop up javascript
$node = node_load(array('nid' => $node->nid));
print $node>-body
not sure if that would work if not try calling a php file from with the javascript
a solution
problem of connection
a solution
Hi,
i'm back in this post with a solution.
the solution is here, it was posted by Vincent in drupalfr.org.
For non frensh speakers, i will try to explain how to to that:
-we must to add a variable to the link for the page that we want to load in the pop-up, example : http://mysite.com/node/18&pop=TRUE
-After , we must to add this portion of code in the template.php file in the theme folder:
-After we must to duplicate the file page.tpl.php, the new file will have page-popup.tpl.php as a name, then we can customize the new template file as we want in order to delete header, footer...
that's all, and sorry for my English
...
A simpler solution is to call-up your node via 'node/1234/popup'. Drupal would automatically use the template 'page-node-popup.tpl.php', if exists. No need to write a function.
http://drupal.org/node/104316
Yeah, this is what I did,
Yeah, this is what I did, thanks. Now I can theme my popup, teach non-techies how to make a popup, and use the FCKEditor popup facilities in combination with this. Nice.
Why isn't this working in
Why isn't this working in Drupal 7?
Template naming has changed
Try page--node--popup.tpl.php
What do you do with the
What do you do with the $vars variable then where do you call it from to activate the pop up
I can't get it to work. The popup page stays in original window
I've implemented the changes as suggested above and I can change the layout of the target page but it does not open up in a popup window. Instead it insists on opening in the original window... By the way, where's the code that actually creates the popup?
(Boy, do I sound like the newbie I am *grin*)
Thanks,
/PWG
To get a link to popup in a new window ...
You need to add the html attribute "target" = "_blank". The way to add this depends on what's rendering your link. If, for example, you are using l(), then you'd want something like ...
Note: Please don't just copy and paste this because that won't work. You need to modify it to suit your circumstances.
Thanks! Petter
Thanks!
Petter
Slight amendment
There are a variety of ways to open a new window. Using target="_blank" is just one of them. Most of the other techniques use javascript.
http://drupal.org/project/nod
http://drupal.org/project/nodeformpopup ?