ViewerUrl Difference 1.13 to 1.15

7 posts by 2 authors in: Forums > CMS Builder
Last Post: May 14, 2008   (RSS)

By jposwald - May 9, 2008 - edited: May 9, 2008

Dave,

In 1.13 we had in ListPage the option to point the ViewerUrl in one category to different webpages when we wanted to sort a List by ID=

For ex in 1.13,
I have the Certifications Category where:

$options['viewerUrl'] = 'Certifications_Management_see.php';

and now in 1.15 i cannot do it because it has to be directly from CMS...

is there a string code to add to certain webpages their viewerurl?

I tried with:

list($certifications_Record, $certifications_Details) = getRecords(array(
'tableName' => 'certifications_',
'perPage' => '10',
'viewerUrl' => 'Certifications_Management_see.php';
));

But it does not work :(

Do you know how to make it work?

Best Regards, Juan

Re: [jposwald] ViewerUrl Difference 1.13 to 1.15

By Dave - May 9, 2008

Hi Juan,

If you've already set this up with the older version, the the old viewer code will work fine, so you can continue to use that if you want.

But you can use the new code as well. Here's how to do it. Note that I'll use $record for the variable name, just replace that with whatever your record variable is called.

Instead of <?php echo $record['_link'] ?>
use this: Certifications_Management_see.php?<?php echo $record['_filename'] ?>-<?php echo $record['num'] ?>

That will create the same kind of link but let you link to a different page. Give that a try and let me know how it works.

Also, one more trick. If you want to see all the values that are available in a variable you can use this code to display them while developing the site:

<xmp><?php print_r($record); ?></xmp>

Hope that helps, let me know how it goes.
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] ViewerUrl Difference 1.13 to 1.15

By jposwald - May 9, 2008

Dave,

It seems not to work yet with:

<a href="Certifications_Management_see.php?<?php echo $record['_filename'] ?>-<?php echo $record['num'] ?> ">

also not with:

<a href="Certifications_Management_see.php?<?php echo $casos_estudio_Record['_filename'] ?>-<?php echo $casos_estudio_Record['num'] ?> ">

I do not why....

Re: [jposwald] ViewerUrl Difference 1.13 to 1.15

By Dave - May 9, 2008

What happens? What does it output? Do you have an url?
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] ViewerUrl Difference 1.13 to 1.15

By jposwald - May 9, 2008

http://www.worldwidetrainings.com/Casos_Estudio_Psicologia_Clinica.php?id=1

I also attached you Casos_Estudio_Psicologia_Clinica.php

It gotta be a simple error I think.

Thank you Dave!

Re: [jposwald] ViewerUrl Difference 1.13 to 1.15

By Dave - May 10, 2008

Hi jposwald,

Sorry, what am I looking for? I search the page source of the url and the attached file for the "Certifications" from the link but couldn't find any matches?

What part should I look at this isn't working right?

Thanks!
Dave Edis - Senior Developer
interactivetools.com

Re: [Dave] ViewerUrl Difference 1.13 to 1.15

By jposwald - May 14, 2008

I already solve it :) Thank you!