We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 11667
    • 12 Posts
    Still not working..
      • 18373 ☆ A M B ☆
      • 3,141 Posts
      I’m noticing the ampersands all are being escaped...

      Where do you put your snippet call? Is it in the content, in the template?

      If in the content, are you escaping the ampersands yourself or is the RTE doing this? If the RTE is doing this, try using no editor or add the snippet calls in the HTML view.

      And yes, you’ll need &docId.
        Mark Hamstra • Developer spending his days working on Premium Extras and a MODX Site Dashboard with the ability to remotely upgrade MODX and extras to make the MODX world a little better.

        Tweet me @mark_hamstra, check my infrequent blog at markhamstra.com, my slightly more frequent ramblings at MODX.today or see code at Github.
        • 11667
        • 12 Posts
        I’ve put the snippet call in document content, i’ve removed the escaping from html source but still makes no difference..
          • 29257
          • 18 Posts
          Please, explain me, is there any way to have different sized thumbnails on different instances of EvoGallery?
          Thanks!
            • 18373 ☆ A M B ☆
            • 3,141 Posts
            Quote from: tambourine at Jun 29, 2010, 09:38 AM

            Please, explain me, is there any way to have different sized thumbnails on different instances of EvoGallery?
            Thanks!

            Try using phpThump or css clip() in the templates you use for the different instances.




            As a sidenote: I updated the EvoGallery Docs today with the placeholders available in the different types (for what I could find by sniffing the code).
              Mark Hamstra • Developer spending his days working on Premium Extras and a MODX Site Dashboard with the ability to remotely upgrade MODX and extras to make the MODX world a little better.

              Tweet me @mark_hamstra, check my infrequent blog at markhamstra.com, my slightly more frequent ramblings at MODX.today or see code at Github.
              • 29257
              • 18 Posts
              Thanks! It works fine and was easy to understand, but it strangely and unpredictably that such option doesn’t available inside EvoGallery.

              Please, give me another advise: is there possible to get width and height of the picture through placeholders?
                • 18373 ☆ A M B ☆
                • 3,141 Posts
                Quote from: tambourine at Jun 30, 2010, 02:38 AM

                Please, give me another advise: is there possible to get width and height of the picture through placeholders?

                Not out of the box.... but here’s a fix to get that functionality:

                				//Start modification to use width and height placeholders, Mark Hamstra, June 30, 2010
                				$imgsize = getimagesize($modx->config['base_path'] . $this->config['galleriesUrl'] . $row['content_id'] . '/' . $row['filename']); 
                				$item_phx->setPHxVariable('width',$imgsize[0]); 
                				$item_phx->setPHxVariable('height',$imgsize[1]); 
                				//End modification

                Put it in the assets/snippets/evogallery/classes/gallery.class.inc.php file, around line 205, as long as it is after the [tt]$item_phx[/tt] declaration and before parsing the templates. Like so:
                			while ($row = $modx->fetchRow($result))
                			{
                				$item_phx = new PHxParser();
                				foreach ($row as $name => $value)
                					$item_phx->setPHxVariable($name, $value);
                
                				//Start modification to use width and height placeholders, Mark Hamstra, June 30, 2010
                				$imgsize = getimagesize($modx->config['base_path'] . $this->config['galleriesUrl'] . $row['content_id'] . '/' . $row['filename']); 
                				$item_phx->setPHxVariable('width',$imgsize[0]); 
                				$item_phx->setPHxVariable('height',$imgsize[1]); 
                				//End modification
                
                				$item_phx->setPHxVariable('images_dir', $this->config['galleriesUrl'] . $row['content_id'] . '/');
                				$item_phx->setPHxVariable('thumbs_dir', $this->config['galleriesUrl'] . $row['content_id'] . '/thumbs/');
                				if(!empty($item_tpl_first) && $count == 1){
                    				$items .= $item_phx->Parse($item_tpl_first);
                				} else if(!empty($item_tpl_last) && $count == $recordCount){
                    				$items .= $item_phx->Parse($item_tpl_last);
                				} else if(!empty($item_tpl_alt) && $count % $this->config['itemAltNum'] == 0){
                    				$items .= $item_phx->Parse($item_tpl_alt);
                				} else {
                    				$items .= $item_phx->Parse($item_tpl);
                				}
                				$count++;
                			}
                  Mark Hamstra • Developer spending his days working on Premium Extras and a MODX Site Dashboard with the ability to remotely upgrade MODX and extras to make the MODX world a little better.

                  Tweet me @mark_hamstra, check my infrequent blog at markhamstra.com, my slightly more frequent ramblings at MODX.today or see code at Github.
                  • 29257
                  • 18 Posts
                  Thanks a lot! Works great!
                    • 13622
                    • 74 Posts
                    Quote from: Mark at Jun 29, 2010, 09:43 AM

                    As a sidenote: I updated the EvoGallery Docs today with the placeholders available in the different types (for what I could find by sniffing the code).

                    Nice thanks for updating and finding all the placeholders...been VERY helpful for myself.
                      • 8790
                      • 526 Posts
                      Hi I post into phpthumb too ( http://modxcms.com/forums/index.php/topic,50671.0.html )
                      but it’s also an Evogal issue.
                      I just can have the standard phpthumb snippet (the ’real one, not the one coming with Evo, that just don’t works for me) to correctly get the path of the evo gallery.

                      The rendered html looks however ok, but it’s likely the path parameter is not interpreted.
                      <img src="[+filename:phpthumb=`&h=100&w=100&zc=1&q=95#[+images_dir+]`+]" .....

                      the html returned is
                      <img title="vue de : blbla" alt="Accueil bla bla" src="/assets/snippets/phpthumb/phpThumb.php?src=snap-image.jpg&h=100&w=100&zc=1&q=95#/assets/galleries/1/">

                      all path are ok, but phpthumb does not find the image because it’s loks for it into its own directory /snippets/phpthumb/imagexxx.jpg, wich is wrong.

                      Plz check my phpthumb post directly for all code and details.


                      thank you
                        Schtroumpf Grognon - Grouchy Smurf
                        ---------------------------------
                        Faites pas attention.. - Don&#39;t pay attention
                        http://www.dzi-neo.net