The method of calling the thumbnail in the productimagelist of the dedecms atlas label

When I used the dedecms atlas model to build a beauty photo site, I found that the {dede:productimagelist} tag could not call up the thumbnails of the pictures, but the webpage just wanted to call the thumbnails of each picture. How can this be achieved?

After researching and publishing.com, it is found that dream weaving dedecms has a mechanism to generate thumbnails for each picture. As long as the display mode is selected as multiple rows and multiple columns when publishing,
please see the corresponding source code:

Open the dedealbum_add.php file and check the red part of the code as follows:
/ ---------------------
function _getformupload()
pictures uploaded normally through swfupload
------ ---------------
/
if(is_array( KaTeX parse error: Expected'}', got'EOF' at end of input: …'])) {foreach( _SESSION['bigfile_info '] as k => k=>k=>v)
{
$truefile = c f g b a s e d i r . cfg_basedir. cfgbasedir.v;
if(strlen( v ) 2 ? G e t I m a g e M a p D D ( v) 2 ? GetImageMapDD( v)2?GetImageMapDD(v, c f g d d i m g w i d t h ) : ′ ′ ; i f ( ! cfg_ddimg_width) : ''; if(! cfgdd i m gwidth):;if(!hasone && $ddisfirst1 && $litpic’’)
{
l i t p i c = e m p t y ( litpic = empty( litpic=empty(litpicname) ? GetImageMapDD($v, $cfg_ddimg_width) : $litpicname;
$hasone = TRUE;
}
i m g i n f o = ! e m p t y ( imginfo = !empty( i m g i n f o=!empty({‘picinfook’.$k}) ? KaTeX parse error: Expected '}', got 'EOF' at end of input: {'picinfook'.k} : ‘’;
KaTeX parse error: Expected '}', got 'EOF' at end of input: …ede:img ddimg='v’ text=’$imginfo’} $v {/dede:img}rn";
}
}

i m g u r l s = a d d s l a s h e s ( imgurls = addslashes( imgurls=addslashes(imgurls);

Pagestyle is the single-page multi-image style, slide style, and multi-thumbnail style selected when publishing the atlas. Choose the third one when publishing the atlas. The multi-thumbnail style is enough. If the number of rows and columns is yours Don’t bother about the template, just set the thumbnail width to an appropriate value. If you didn’t select it when publishing, it’s easy to generate thumbnails. Just change the published atlas and select multiple The thumbnail style is enough so that the thumbnail of each picture is generated, but how can I call it out? First look at the pictures stored in the database, and then look at the blue part of the code above. According to the judgment, pagestyle is the single-page multi-image style, slide style, and multiple thumbnail styles selected when publishing the atlas. The third is to use multiple thumbnail styles. If the number of rows and columns is your own template, don’t bother about it. Just set the width of the thumbnail to an appropriate value. If you didn’t select it when publishing, you still want it. Generating thumbnails is also very simple. Just change the published atlas and select multiple thumbnail styles so that the thumbnails of each picture are generated, but how can I call them? First look at the pictures stored in the database and then look at the blue part of the code above, according to judgmentP A G E S T Y L E can be made of cloth FIG set when the selected selection of the single -page multi FIG comp formula , magic lamp sheet -like type , multi shrink slightly FIG comp formula these three Species in hair cloth FIG set when selected from the selection of three th , multi shrink slightly FIG comp formula i.e., may, Row number and column number as if a self- own the mold plate is then not necessarily reason will , just to set a given reduced slightly FIG width of the engagement proper of the number of values to be in the as if your hair cloth of time candidate is not selected from , you may also want to green to shrink slightly FIGS alsoVery simple single , only need more changes have been made cloth of FIG set , selected from the group of the plurality shrink slightly FIG comp formula on the line of this kind each of a FIG sheet of shrink slightly FIG on green to a to a , it may be how it was able to tune with the come of it ? To see a lower numberAccording database storing saved in FIG sheet again to see the face of substituting codes in the blue color portion points , the root according to judgment off ddimg thumbnail is the
open file /include/taglib/productimagelist.lib.php
find it and other labels different place , It is a mechanism to read the value and attribute of one label to display in another label,
then add a new read attribute where it processes the label, just add the red part of the following code to complete this function

if($ctag->GetName()==“img”)
{
$row = array();
r o w [ ′ i m g s r c ′ ] = t r i m ( row['imgsrc'] = trim( row[imgsrc]=trim(ctag->GetInnerText());
$row[‘text’] = $ctag->GetAtt(‘text’);
r o w [ ′ l i t p i c ′ ] = row['litpic'] = row[litpic]=ctag->GetAtt(‘ddimg’);
$images[] = $row;
}

In this way [field:litpic/] can display the thumbnail corresponding to the picture

Guess you like

Origin blog.csdn.net/a9490489/article/details/106892589