coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 cpmFetch by vuud => Topic started by: judl on December 07, 2009, 11:03:58 PM

Title: Return only IMG tag with no <table> <td> <tr>?
Post by: judl on December 07, 2009, 11:03:58 PM
I am trying to make a call to cpmfetch and insert html code smartly into my page. The php seems to return an entire <table>. Is there an option so I can just get back the image tag?

Thanks in advance,
Chris
Title: Re: Return only IMG tag with no <table> <td> <tr>?
Post by: Nibbler on December 07, 2009, 11:10:47 PM
Use


$objCpm->cpm_setReturnType('resultset');


Then format the data as you wish.
Title: Re: Return only IMG tag with no <table> <td> <tr>?
Post by: judl on December 08, 2009, 01:36:01 AM
Seems like there have been a lot of posts about this. Everyone seems to take their own tact. If there is some sample code on how to deal with the resultset data set, it would be appreciated.
Title: Re: Return only IMG tag with no <table> <td> <tr>?
Post by: vuud on April 04, 2010, 03:23:24 AM
Quote from: judl on December 08, 2009, 01:36:01 AM
Seems like there have been a lot of posts about this. Everyone seems to take their own tact. If there is some sample code on how to deal with the resultset data set, it would be appreciated.

This gets into just plain old PHP.  If you pick up on learning some basic PHP you will be fine.  The results come back as an array, and you just need to loop through them.

Google on stuff like