Author Topic: Droplet error n a Wysiwyg page  (Read 6651 times)

Offline marcomesa

  • Posts: 39
Droplet error n a Wysiwyg page
« on: August 14, 2012, 08:21:21 AM »
Hi,
I try to add a droplet to a wysiwyg page, but I get only this kind of result [[droplet Name]] and no php code is shown on the page. Could you tell me how to solve? Somebody told me to switch off the sunhosin eval in my server, but my host provider already told me there is no sunhosin active on my server...

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #1 on: August 14, 2012, 09:35:47 AM »
Hi,
in the index.php of your template exist this line?:
Code: [Select]
register_frontend_modfiles('js');

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #2 on: August 14, 2012, 09:42:20 AM »
yes I found this one

Quote
if(function_exists('register_frontend_m odfiles')) {
   register_frontend_m odfiles('css');
   register_frontend_m odfiles('js');

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #3 on: August 14, 2012, 09:49:26 AM »
good ...
maybe you have a javascript-error on the page?
give us a link.

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #4 on: August 14, 2012, 10:02:05 AM »
ok this is the link

http://www.beavita.it/pages/gallery.php

as you can see WebsiteBaker simply add [[SiteMapChild]] and not a php code. It is like it doesnt recognize the droplet command. I dont get any javascript error...Just push the droplet button, choose the droplet and I get only a plain text between square parenthesis...very odd...

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #5 on: August 14, 2012, 10:12:29 AM »
first try: all your code bevor/above this line:
Code: [Select]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">should down to the end of body:
Code: [Select]
</body>
« Last Edit: August 14, 2012, 11:32:52 AM by dbs »

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #6 on: August 14, 2012, 10:27:20 AM »
 :?
hmmmm what you mean? I don't understand...

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #7 on: August 14, 2012, 10:32:33 AM »
i mean the tracking-code, to find in the head of index.php of your template.

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #8 on: August 14, 2012, 10:36:58 AM »
Ok I move all the code beetween
Quote
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

and

Quote
<body class="body<?php echo $page_id; ?>">

to the end of body....but nothing change...

maybe you mean something else...please forgive me but I don't know exactly what is the tracgin code...
« Last Edit: August 14, 2012, 10:39:59 AM by marcomesa »

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #9 on: August 14, 2012, 11:31:32 AM »
better you post the content of index.php of your template here.
plz use the #-button for this.

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #10 on: August 14, 2012, 11:33:05 AM »
Here it is my index.php file... :-)

Code: [Select]
<?php

if(!defined('WB_URL')) {
header('Location: ../index.php');
exit(0);
}

?>

<!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" xml:lang="en" lang="en">
<head>
<?php if(function_exists('simplepagehead')) {
simplepagehead(); 
} else { 
?>

<title><?php page_title(); ?></title>
<meta http-equiv="Content-Type" content="text/html; charset=<?php if(defined('DEFAULT_CHARSET')) { echo DEFAULT_CHARSET; } else { echo 'utf-8'; }?>" />
<meta name="description" content="<?php page_description(); ?>" />
<meta name="keywords" content="<?php page_keywords(); ?>" />
<?php 

if(function_exists('register_frontend_modfiles')) {
register_frontend_modfiles('css');
register_frontend_modfiles('js');
?>

<link href="<?php echo TEMPLATE_DIR?>/editor.css" rel="stylesheet" type="text/css" />
<link href="<?php echo TEMPLATE_DIR?>/template.css" rel="stylesheet" type="text/css" />


<script type="text/javascript" src="<?php echo TEMPLATE_DIR;?>/standard.js"></script>
<script type="text/javascript">
   var xmlhttpPostLinkURL = "<?php echo TEMPLATE_DIR;?>/quicksearch.php";
</script>

<!--[if lte IE 6]>
<style type="text/css" media="all">
@import "<?php echo TEMPLATE_DIR?>/ie6.css";
body {behavior: url("<?php echo TEMPLATE_DIR?>/csshover.htc");}
</style>
<![endif]-->
</head>
<body class="body<?php echo $page_id?>">


<div id="fb-root"></div>
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>


<a id="top"></a><div class="stealth"><a href="#beginContent">skip to content</a></div>
<div class="bodybox">
<div class="headerbox">
<div class="logobox"><a class="logo" href="<?php echo WB_URL?>"><span><?php echo WEBSITE_TITLE?></span></a>
<div class="search_box">
<form name="search" id="search" action="<?php echo WB_URL?>/search/index.php" method="get">
<input type="hidden" name="referrer" value="<?php echo defined('REFERRER_ID')?REFERRER_ID:PAGE_ID;?>" /><input type="text" value="<?php if (isset($_GET['string'])) {echo strip_tags($_GET['string']);} else {echo 'Suche'; } ?>" name="string" class="searchstring" onfocus="if (this.value=='Suche') {this.value='';}" onkeyup="initsuggestion(this.value);"  /><input type="image"  class="submitbutton" src="<?php echo TEMPLATE_DIR?>/img/searchbutton.gif" alt="Start" />
</form><div id="suggestbox"></div>
</div><!-- end searchbox -->
</div><!-- end logobox -->

<div class="menuebox"><div id="nav">
<?php show_menu2(1SM2_ROOTSM2_ALLSM2_ALL'<li><a href="[url]" class="[class]"><span>[menu_title]</span></a>'"</li>"'<ul>'"</ul>"true'<ul id="header_menu" class="menu">');?><br style="clear:left;"/>
</div><!-- end nav --></div><!-- end menuebox -->
</div><!-- end headerbox -->

<div class="leftbox">
<div class="inner"><h2><?php echo PAGE_TITLE ?></h2><p><b><?php page_description(); ?></b></p></div> &nbsp &nbsp &nbsp info@beavita.it
<div class="leftmenu"><?php show_menu(2SM2_ROOT,  SM2_CURR+1true'<li><span[class]>[a][menu_title] [/a]</span>','</li>''<ul>''</ul>'' class="menu_default"'' class="menu_current"',0); ?></div>
<?php if(FRONTEND_LOGIN) { include('login.inc.php'); } ?><!--LOGIN_URL, LOGOUT_URL,FORGOT_URL-->
&nbsp;
<div class="fb-like" data-href="http://www.beavita.it/" data-send="true" data-layout="button_count" data-width="450" data-show-faces="true"></div>
</div><!--end leftbox-->


<div class="mainbox">
<div class="breadcrumbs"><div class="innerbc">
<?php 
if (LEVEL 1) {
show_menu2(0SM2_ROOTSM2_ALLSM2_CRUMB'<span class="[class]">[a][menu_title]</a></span>''''''''...<span class="[class]">[a][menu_title]</a></span>'); 
} else {
show_menu2(0SM2_ROOTSM2_ALLSM2_CRUMB'<span class="[class]">[a][menu_title]</a></span>''''''''You are here: <a href="/">Home</a> <span class="[class]">[a][menu_title]</a></span>'); 
}
?>
</div></div><!-- end breadcrumbs -->



<div class="content">
<?php 
ob_start(); 
page_content(1);
$page_content1 ob_get_contents();
ob_end_clean();
echo $page_content1
?>

</div><!-- end content -->

<div class="rightbox">
<div class="inner"><?php page_content(2); ?></div>
<div style="clear:left; height:1px;"></div>
</div><!-- end rightbox -->

</div><!-- end mainbox -->
<div class="clearcontent"></div>
</div><!-- end bodybox -->
<div class="clearcontent"></div>
<div class="footerbox"><div class="left">&nbsp; <?php if ($page_id 10 AND $page_id == 0) {echo 'Designed by <a href="http://www.beesign.com/" target="_blank">Webdesign Wien</a>'; } ?></div><div class="center"><?php page_footer(); ?></div></div>
</body>
</html>

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #11 on: August 14, 2012, 11:44:06 AM »
this looks good!
but it is not the same like the source-code on your website.
this was the right index.php? sure?

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #12 on: August 14, 2012, 11:47:54 AM »
Yes it is the index of the template, in fact you can find the facebook like button script that I added by myself...I don't know why it is different  in the website  :?

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #13 on: August 14, 2012, 11:59:18 AM »
first i see in the sourcecode google-analytics-code
than 1 line DOCTYPE
than <body>
than facebook ...

next try: put the facebook-code to the end of the body
Code: [Select]
<script>(function(d, s, id) {
  var js, fjs = d.getElementsByTagName(s)[0];
  if (d.getElementById(id)) return;
  js = d.createElement(s); js.id = id;
  js.src = "//connect.facebook.net/en_US/all.js#xfbml=1";
  fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));</script>
above this line:
Code: [Select]
</body>

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #14 on: August 14, 2012, 12:08:51 PM »
aaah yes the analitycs I put it in the index of the website...yes you're right...I can remove it if you think it can be the problem. I put it there because I didint know how WebsiteBaker works... :-D

I moved the facebook script at the end of body...nothing.
When I push the droplet button in the editor it make me choose a droplet than simply in the editor I get [[SitemapChild]] as plain text...I try to view the page but I still see plain text. It seems WebsiteBaker doesnt activate the droplet...

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #15 on: August 14, 2012, 12:27:04 PM »
put the ga-code also to the end of body.
end of body means before </body>, not after. ;o)

Offline marcomesa

  • Posts: 39
Re: Droplet error on a Wysiwyg page
« Reply #16 on: August 14, 2012, 12:38:19 PM »
ops sorry...my bad....
Ok I think I did the homework...put the 2 scripts at the of the body....before the
Code: [Select]
/body  :-)

unfortunately still nothing changes...
 thanks for helping me... :-)

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #17 on: August 14, 2012, 12:53:34 PM »
your index is now ok.  :-)
i have no idea at the moment why droplets not work.
droplets-script will loaded, droplet SiteMapChild is available, ...

which version of WebsiteBaker?
which droplet-version?

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #18 on: August 14, 2012, 12:58:32 PM »
Oh no  :oops:

I really want to use droplet otherwise I have to make a siteindex all by hand...neverending task...

My Wb is 2.8.1 revision 1287
My droplet is 1.0.2

Offline dbs

  • Betatester
  • **
  • Posts: 8008
  • Gender: Male
  • tioz4ever
    • WebsiteBaker - jQuery-Plugins - Module - Droplets - Tests
Re: Droplet error n a Wysiwyg page
« Reply #19 on: August 14, 2012, 01:04:27 PM »
try another droplet. try another page for droplet. try another template.

for sitemap is also a page-modul available.
http://www.websitebakers.com/pages/modules/listings/section-pages/sitemap.php

Offline marcomesa

  • Posts: 39
Re: Droplet error n a Wysiwyg page
« Reply #20 on: August 14, 2012, 01:47:32 PM »
oh thanks...I used the module... :wink: