Page 1 of 1

[Solved] Print pdf does not work

Posted: Sun Apr 05, 2009 1:49 pm
by JohnnyTheOne
if I change manually that line $html=$props->mPropertyValues["content_en"]; in createpdf.php it works

Re: Print pdf does not work

Posted: Sun Apr 05, 2009 10:00 pm
by alby
JohnnyTheOne wrote: if I change manually that line $html=$props->mPropertyValues["content_en"]; in createpdf.php it works
Confirmed and present in next release:

substitute (around #100) with:
//Start MLE
global $mleblock, $mleblockfallback;
$block = (!empty($mleblock)) ? (!empty($mleblockfallback) ? $mleblockfallback : $mleblock) : "_en";
$html=$props->mPropertyValues["content".$block];
//End MLE
Thank you  :)

Alby

Re: Print pdf does not work

Posted: Mon Apr 06, 2009 10:10 pm
by JohnnyTheOne
Thanks for the quick response but it does not work

Re: Print pdf does not work

Posted: Tue Apr 07, 2009 7:09 am
by alby
JohnnyTheOne wrote: Thanks for the quick response but it does not work
Have you substitute the row?
Tried and work for me

Alby

Re: Print pdf does not work

Posted: Tue Apr 07, 2009 10:50 pm
by JohnnyTheOne
alby wrote: Have you substitute the row?
yes, here is what I did

Code: Select all

//Start MLE
global $mleblock, $mleblockfallback;
$block = (!empty($mleblock)) ? (!empty($mleblockfallback) ? $mleblockfallback : $mleblock) : "_en";
$html=$props->mPropertyValues["content".$block];
//End MLE
//$html=$props->mPropertyValues["content_en"];

Re: Print pdf does not work

Posted: Wed Apr 08, 2009 7:43 am
by alby
JohnnyTheOne wrote:
alby wrote: Have you substitute the row?
yes, here is what I did
I re-tried and works for me with content of all languages

Alby

Re: Print pdf does not work

Posted: Wed Apr 08, 2009 11:41 pm
by JohnnyTheOne
the problem is with me I will continue looking thanks

Re: [Solved] Print pdf does not work

Posted: Wed Apr 15, 2009 4:47 pm
by JohnnyTheOne
Show from DEFAULT_LANG if current lang is not ready:
it must not be selected :'(

maybe you have a solution for this function is very useful

Re: [Solved] Print pdf does not work

Posted: Wed Apr 15, 2009 6:23 pm
by alby
JohnnyTheOne wrote:
Show from DEFAULT_LANG if current lang is not ready:
it must not be selected :'(

maybe you have a solution for this function is very useful
humm, you are right.....
Try with:
//Start MLE
global $mleblock, $mleblockfallback;
$block = (!empty($mleblock)) ? $mleblock : (!empty($mleblockfallback) ? $mleblockfallback : "_en");
$html=$props->mPropertyValues["content".$block];
//End MLE
Alby

Re: [Solved] Print pdf does not work

Posted: Wed Apr 15, 2009 6:45 pm
by JohnnyTheOne
work now thanks

Re: [Solved] Print pdf does not work

Posted: Wed Apr 15, 2009 7:11 pm
by alby
yes but not like this ..... I think something  :-\

Alby

Re: [Solved] Print pdf does not work

Posted: Wed Apr 15, 2009 8:17 pm
by alby
Sorry for wrong code,
this is the working code that I add in next release:
//Start MLE
global $mleblock, $mleblockfallback;
$param1 = !empty($mleblock) ? $mleblock : '_en';
$param2 = !empty($mleblockfallback) ? str_replace($mleblock, $mleblockfallback, $param1) : '_en';
$html=$props->mPropertyValues['content'.$param1];
if( (!empty($mleblockfallback)) && (empty($html)) && ($param1 != $param2) ) $html=$props->mPropertyValues['content'.$param2];
//End MLE
Alby