11
script_fu
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error

I have verified that the .jpg format will work in news and can be turned into a .pdf

Now when you download a thumb from extgallery the format of the picture is hook-thumb.php.jpg and they work when you click on them.

So Mr. Zoullou is doing the code correct as a thumb. But somewhere the .jpg info its getting lost by TCPDF when ported into the .pdf

So does this now lead us away from Z's code and put it back on TCPDF? Or is the issue really in extgallery.

Any bets on this people? How can you tell for sure were the problem lays?

12
Will_H
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error
  • 2008/2/1 23:09

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


you missed my post.

The problem is extgal...

Should I even bother posting, as it seems you refuse to listen to me.

13
script_fu
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error

I am listening to you. Because of your posts we are getting closer to fixing the problem.

You are under the opinion it is in extgallery. Good I understand you position. You also said the issue can be solved in the image manager.

Would you be so kind as to post your fix?

Now I think Z's code is working like it should. When you right click the thumb and hit save its a .jpg

This leads me to think that the issue might not be in the extgallery module.

This is how issues get solved. By working together. You don't half to talk down to me or better yet treat me like a fool.

You really might not be correct about this... But you keep coming here and insisting that the problem is this or that without the code is helping know one.

14
Will_H
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error
  • 2008/2/1 23:25

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


Listen.

The makepdf is set to recognize images.

So lets try and trick it into thinking these are images.

original
// eXtGallery Hack
$patterns[] = "/[gallery]([0-9]*)[/gallery]/sU";
$replacements[] = '.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\1" rel="lightbox">.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\1" alt="" />';

$patterns[] = "/[gallery title=(['"]?)([ a-zA-Z0-9]*)\1]([0-9]*)[/gallery]/sU";
$replacements[] = '/modules/extgallery/hook-photo.php?id=\3" rel="lightbox" title="\2" alt="\2">/modules/extgallery/hook-thumb.php?id=\3" alt="\2" title="\2" />';

$patterns[] = "/[gallery group=(['"]?)([a-zA-Z0-9]*)\1]([0-9]*)[/gallery]/sU";
$replacements[] = '
<a href="'.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\3" rel="lightbox[\2]"><img src="'.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\3" alt="" />a>';

$patterns[] = "/[gallery group=(['"]?)([a-zA-Z0-9]*)\1 title=(['"
]?)([ a-zA-Z0-9]*)\3]([0-9]*)[/gallery]/sU";
$replacements[] = '/modules/extgallery/hook-photo.php?id=\5" rel="lightbox[\2]" title="\4" alt="\4">/modules/extgallery/hook-thumb.php?id=\5" title="\4" alt="\4" />';

$patterns[] = "/[gallery title=(['"]?)([ a-zA-Z0-9]*)\1 group=(['"]?)([a-zA-Z0-9]*)\3]([0-9]*)[/gallery]/sU";
$replacements[] = '.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\5" rel="lightbox[\4]" title="\2" alt="\2">.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\5" title="\2" alt="\2" />';
// End eXtGallery Hack


As .jpgs
// eXtGallery Hack
$patterns[] = "/[gallery]([0-9]*)[/gallery]/sU";
$replacements[] = '.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\1.jpg" rel="lightbox">.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\1" alt="" />';

$patterns[] = "/[gallery title=(['"]?)([ a-zA-Z0-9]*)\1]([0-9]*)[/gallery]/sU";
$replacements[] = '/modules/extgallery/hook-photo.php?id=\3.jpg" rel="lightbox" title="\2" alt="\2">/modules/extgallery/hook-thumb.php?id=\3" alt="\2" title="\2" />';

$patterns[] = "/[gallery group=(['"]?)([a-zA-Z0-9]*)\1]([0-9]*)[/gallery]/sU";
$replacements[] = '
<a href="'.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\3.jpg" rel="lightbox[\2]"><img src="'.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\3" alt="" />a>';

$patterns[] = "/[gallery group=(['"]?)([a-zA-Z0-9]*)\1 title=(['"
]?)([ a-zA-Z0-9]*)\3]([0-9]*)[/gallery]/sU";
$replacements[] = '/modules/extgallery/hook-photo.php?id=\5.jpg" rel="lightbox[\2]" title="\4" alt="\4">/modules/extgallery/hook-thumb.php?id=\5" title="\4" alt="\4" />';

$patterns[] = "/[gallery title=(['"]?)([ a-zA-Z0-9]*)\1 group=(['"]?)([a-zA-Z0-9]*)\3]([0-9]*)[/gallery]/sU";
$replacements[] = '.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\5.jpg" rel="lightbox[\4]" title="\2" alt="\2">.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\5" title="\2" alt="\2" />';
// End eXtGallery Hack


I went ahead and implemented this on your site. They have a .jpg extension at the very end... but thats only after its been terminated by the .php?id=64

Right now it reads like .php?id=64.jpg

Yeah, extgal hooks still work. Properties shows em with a .jpg extension at the end... but... .php?id=64 kills it.

15
Will_H
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error
  • 2008/2/1 23:28

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


Ok got it working

Fixed to make pdf

// eXtGallery Hack
$patterns[] = "/[gallery]([0-9]*)[/gallery]/sU";
$replacements[] = '.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\1.jpg" rel="lightbox">.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\1.jpg" alt="" />';

$patterns[] = "/[gallery title=(['"]?)([ a-zA-Z0-9]*)\1]([0-9]*)[/gallery]/sU";
$replacements[] = '/modules/extgallery/hook-photo.php?id=\3.jpg" rel="lightbox" title="\2" alt="\2">/modules/extgallery/hook-thumb.php?id=\3.jpg" alt="\2" title="\2" />';

$patterns[] = "/[gallery group=(['"]?)([a-zA-Z0-9]*)\1]([0-9]*)[/gallery]/sU";
$replacements[] = '
<a href="'.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\3.jpg" rel="lightbox[\2]"><img src="'.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\3.jpg" alt="" />a>';

$patterns[] = "/[gallery group=(['"]?)([a-zA-Z0-9]*)\1 title=(['"
]?)([ a-zA-Z0-9]*)\3]([0-9]*)[/gallery]/sU";
$replacements[] = '/modules/extgallery/hook-photo.php?id=\5.jpg" rel="lightbox[\2]" title="\4" alt="\4">/modules/extgallery/hook-thumb.php?id=\5.jpg" title="\4" alt="\4" />';

$patterns[] = "/[gallery title=(['"]?)([ a-zA-Z0-9]*)\1 group=(['"]?)([a-zA-Z0-9]*)\3]([0-9]*)[/gallery]/sU";
$replacements[] = '.XOOPS_URL.'/modules/extgallery/hook-photo.php?id=\5.jpg" rel="lightbox[\4]" title="\2" alt="\2">.XOOPS_URL.'/modules/extgallery/hook-thumb.php?id=\5.jpg" title="\2" alt="\2" />';
// End eXtGallery Hack

16
script_fu
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error

Well that certainly fixed the problem. Thank you Will! I can only assume you patched both the frameworks and the class module.textsanitizer.php ??

For others who might need this. This hack shuts down any other picture format that you might want to use with lightbox. Only .jpg files will work with this hack.

It suits what I need to do and thus is the solution to my problem. Another big thank you goes out to Will for the fix.

-----

Now that the pdf on the fly is working I have another issue about the formatting of them.

I will start a new topic about this.

17
Will_H
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error
  • 2008/2/2 5:01

  • Will_H

  • Friend of XOOPS

  • Posts: 1786

  • Since: 2004/10/10


of course I did.

btw, who was right and who was wrong?

Looks like the problem was with ... gasp extgal...

18
qcorek
Re: Lightbox, gallery tags, news 1.56 & Pdf problems with TCPDF error
  • 2008/2/5 21:12

  • qcorek

  • Just popping in

  • Posts: 68

  • Since: 2007/10/7


what is hook hack and how to install light box for extGallery?

Login

Who's Online

176 user(s) are online (102 user(s) are browsing Support Forums)


Members: 0


Guests: 176


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Nov 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits