1 | {footer_script} |
---|
2 | jQuery(function($) { |
---|
3 | |
---|
4 | if($('#metaogimagesaveAid').children("option:selected").val()=="-20"){ |
---|
5 | $('#mognp').show(); |
---|
6 | } |
---|
7 | |
---|
8 | $('#metaogimagesaveAid').change(function(event){ |
---|
9 | var idphoto=$(this).children("option:selected").val(); |
---|
10 | var realbum=$('#metaogimagesaveA2id').data('realbum'); |
---|
11 | $('#metaogimagesaveA2id').val(idphoto); |
---|
12 | if($('#metaogimagesaveAid').children("option:selected").val()=="-10" || $('#metaogimagesaveAid').children("option:selected").val()=="-20" || idphoto==realbum){ |
---|
13 | $('#mognp').show(); |
---|
14 | $('#metaogimagescrA').attr("src",''); |
---|
15 | $('#metaogimagescrA').hide(); |
---|
16 | }else{ |
---|
17 | var urliog=$('#metaogimagesaveAid').children("option:selected").data('url'); |
---|
18 | $('#metaogimagescrA').attr("src",urliog); |
---|
19 | $('#mognp').hide(); |
---|
20 | $('#metaogimagescrA').show(); |
---|
21 | } |
---|
22 | $('#mognpe').hide(); |
---|
23 | $('#metaogimagesaveAid').css('border', 'solid 1px #999'); |
---|
24 | $('#metaogimagesaveA2id').css('border', 'solid 1px #999'); |
---|
25 | $('input[name=submit]').show(); |
---|
26 | }); |
---|
27 | |
---|
28 | $('#metaogimagesaveA2id').change(function(){ |
---|
29 | var idphoto2=$(this).val(); |
---|
30 | var realbum=$('#metaogimagesaveA2id').data('realbum'); |
---|
31 | $('#metaogimagesaveAid').val(idphoto2); |
---|
32 | |
---|
33 | if($('#metaogimagesaveAid').children("option:selected").val()==idphoto2){ |
---|
34 | $('#metaogimagesaveAid').css('border', 'solid 1px #999'); |
---|
35 | $('#metaogimagesaveA2id').css('border', 'solid 1px #999'); |
---|
36 | $('#mognpe').hide(); |
---|
37 | $('input[name=submit]').show(); |
---|
38 | if($('#metaogimagesaveAid').children("option:selected").val()=="-10" || $('#metaogimagesaveAid').children("option:selected").val()=="-20"|| idphoto2==realbum){ |
---|
39 | $('#mognp').show(); |
---|
40 | $('#metaogimagescrA').attr("src",''); |
---|
41 | $('#metaogimagescrA').hide(); |
---|
42 | }else{ |
---|
43 | var urliog=$('#metaogimagesaveAid').children("option:selected").data('url'); |
---|
44 | $('#metaogimagescrA').attr("src",urliog); |
---|
45 | $('#mognp').hide(); |
---|
46 | $('#metaogimagescrA').show(); |
---|
47 | } |
---|
48 | }else{ |
---|
49 | $('#metaogimagesaveAid').css('border', 'solid 2px red'); |
---|
50 | $('#metaogimagesaveA2id').css('border', 'solid 2px red'); |
---|
51 | $('#mognpe').show(); |
---|
52 | $('#mognp').hide(); |
---|
53 | $('#metaogimagescrA').attr("src",''); |
---|
54 | $('input[name=submit]').hide(); |
---|
55 | $('#metaogimagescrA').hide(); |
---|
56 | } |
---|
57 | }); |
---|
58 | |
---|
59 | }); |
---|
60 | {/footer_script} |
---|
61 | |
---|
62 | |
---|
63 | <p> |
---|
64 | <strong>{'Metadata Open Graph - Plugin meta og'|@translate}</strong> |
---|
65 | <br> |
---|
66 | <br> |
---|
67 | <span style="margin: 0 0 0 20px">{'Metadata Open Graph title'|@translate}</span> |
---|
68 | <br> |
---|
69 | <input type="hidden" name="metaogidA" value="{$metaog_editA.metaogidid}"> |
---|
70 | <input type="hidden" name="metaogidobjA" value="{$metaog_editA.metaogidobj}"> |
---|
71 | <span style="margin: 0 0 0 20px"><input type="text" name="metaogtitlesaveA" value="{$metaog_editA.metaogtitle}" size="100" maxlenght="100"></span> |
---|
72 | <br> |
---|
73 | <br> |
---|
74 | <span style="margin: 0 0 0 20px">{'Metadata Open Graph description'|@translate}</span> |
---|
75 | <br> |
---|
76 | <span style="margin: 0 0 0 20px"><textarea rows="2" cols="60" name="metaogdescriptionsaveA" id="metaogdescriptionsaveA" class="metaogdescriptionsaveA">{$metaog_editA.metaogdescription}</textarea></span> |
---|
77 | <br> |
---|
78 | <br> |
---|
79 | {if ($SHOWMOGI==1)} |
---|
80 | <span style="margin: 0 0 0 20px">{'Metadata Open Graph link image'|@translate}</span> |
---|
81 | <br> |
---|
82 | <span style="margin: 0 0 0 20px"> |
---|
83 | <input data-realbum="{$metaog_editA.metaogrealbum}" id="metaogimagesaveA2id" type="number" name="metaogimagescrA2" value="{$metaog_editA.metaogimage}"> {'or'|@translate} |
---|
84 | <select id="metaogimagesaveAid" name="metaogimagesaveA"> |
---|
85 | <option value="-20">-----</option> |
---|
86 | <option value="-10">{'use representative photo for this album'|@translate}</option> |
---|
87 | {foreach from=$info_photos item=infophoto} |
---|
88 | <option data-url="{$infophoto.PHOTOURL}" value="{$infophoto.PHOTOID}" {$infophoto.PHOTOSELECT}>{$infophoto.PHOTOINFO}</option> |
---|
89 | {/foreach} |
---|
90 | </select> |
---|
91 | </span> |
---|
92 | <br> |
---|
93 | <span style="margin: 0 0 0 20px"><span style="display:none;" id="mognp">{'use representative photo for this album'|@translate}</span></span> |
---|
94 | <span style="margin: 0 0 0 20px"><span style="display:none;" id="mognpe">{'This ID isn\'t used in your gallery'|@translate}</span></span> |
---|
95 | <br> |
---|
96 | <img id="metaogimagescrA" src="{$metaog_editA.metaogpath}"><br> |
---|
97 | <br> |
---|
98 | {/if} |
---|
99 | </p> |
---|
100 | <p style="margin:0">'; |
---|