windowtarget problems windowtarget problems
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

windowtarget problems

Started by farmerjeffe, March 07, 2007, 01:31:09 AM

Previous topic - Next topic

0 Members and 3 Guests are viewing this topic.

farmerjeffe

this is my code for my "updates" for my website for the gallery so far:

<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$options = array( "windowtarget" => "_blank" );
$objCpm->cpm_viewLastAddedMediaFrom 14$source "cat=8,12:album=19,21,26,25" );
$objCpm->cpm_close();
?>


I have followed the instructions but the picture links still open in the parent target!?!?

Nibbler

You have to actually give it the options...


$objCpm->cpm_viewLastAddedMediaFrom ( 1, 4, "cat=8,12:album=19,21,26,25", $options);

vuud

Quote from: farmerjeffe on March 07, 2007, 01:31:09 AM
this is my code for my "updates" for my website for the gallery so far:

<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$options = array( "windowtarget" => "_blank" );
$objCpm->cpm_viewLastAddedMediaFrom 14$source "cat=8,12:album=19,21,26,25" );
$objCpm->cpm_close();
?>


I have followed the instructions but the picture links still open in the parent target!?!?


You defined the options correctly... you just did nothing with it after that.

The $options array has to be passed as a parameter into the functions you are using it with
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

farmerjeffe

Ah thanks you two!!

I have one last question. I have been kicking myself trying to figure out how the hell to show when it was uploaded and who by underneath  each image but i just cant figure it out!

I promise i have read the Docs in the download AND on the fistfullofcodes site!!

Gah sorry

appreciate it if you could hlep. Sorry.

vuud

Quote from: farmerjeffe on March 07, 2007, 01:44:41 AM
Ah thanks you two!!

I have one last question. I have been kicking myself trying to figure out how the hell to show when it was uploaded and who by underneath  each image but i just cant figure it out!

I promise i have read the Docs in the download AND on the fistfullofcodes site!!

Gah sorry

appreciate it if you could hlep. Sorry.

Ah you promise you read the docs...

and yet...

http://www.fistfullofcode.com/projects/copperminefetch/manual/ch06s03.html

Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

farmerjeffe

I read that, got confused. Im not lying. Yet i just spotted that the information goes in the options array! I was pondering over where to write the code!!!

Thanks!!

farmerjeffe

Ok so im practising what comes up by just typing in %d and seein gif it shows the album description and i get an error, heres my code:

<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$options = array( "windowtarget" => "_blank" "subtitle" => "%d" );
$objCpm->cpm_viewLastAddedMediaFrom 14$options$source "cat=8,12:album=19,21,26,25" );
$objCpm->cpm_close();
?>


What am i doing wrong?

thanks

adam

Nibbler

Wrong way round I think

$objCpm->cpm_viewLastAddedMediaFrom ( 1, 4, "cat=8,12:album=19,21,26,25", $options);

farmerjeffe

I just tryed that but still has the same error and this is my code now:

<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$options = array( "windowtarget" => "_blank" "subtitle" => "%d" );
$objCpm->cpm_viewLastAddedMediaFrom 14"cat=8,12:album=19,21,26,25"$options);
$objCpm->cpm_close();
?>

farmerjeffe

Hey i just figure dout what was wrong! was missing a comma to seperate the options!


thanks for you help guys!!

adam

vuud

Quote from: farmerjeffe on March 07, 2007, 02:16:47 AM
Hey i just figure dout what was wrong! was missing a comma to seperate the options!


thanks for you help guys!!

adam

Good. 

You need to work on posting as a knee jerk reaction...   If you get an error try to work it out first.

Regards,

Vuud
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

farmerjeffe

Yeh sorry! my bad! Is there a way of making the subtitles closer to the the images!? cause there pretty far down underneath!

farmerjeffe

and lastly (last thing i promise) i cant seem to find how to show the text so it has a property on each line

E.G.

My video
Posted by Adam
March 07

vuud

Quote from: farmerjeffe on March 07, 2007, 02:27:10 AM
Yeh sorry! my bad! Is there a way of making the subtitles closer to the the images!? cause there pretty far down underneath!

Post your code and a link to it happening.  They should not be that far down.
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

vuud

Quote from: farmerjeffe on March 07, 2007, 02:32:21 AM
and lastly (last thing i promise) i cant seem to find how to show the text so it has a property on each line

E.G.

My video
Posted by Adam
March 07

You are going to be the inspiration for rate / limiting connections to SMF

Insert <BR /> tags...  It just outputs HTML
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

farmerjeffe

<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$options = array( "windowtarget" => "_blank""subtitle" => " %a <br> %w " );
$objCpm->cpm_viewLastAddedMediaFrom 14"cat=8,12:album=19,21,26,25"$options);
$objCpm->cpm_close();
?>



that is my code.

vuud

Quote from: farmerjeffe on March 07, 2007, 02:37:09 AM
<?php 
include "./cpmfetch/cpmfetch.php";
$objCpm = new cpm("/gallery");
$options = array( "windowtarget" => "_blank""subtitle" => " %a <br> %w " );
$objCpm->cpm_viewLastAddedMediaFrom 14"cat=8,12:album=19,21,26,25"$options);
$objCpm->cpm_close();
?>



that is my code.


Nothing looks weird there.  Without a screenshot or a link though, I can't tell you if what you are seeing is normal.

Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

farmerjeffe

Well it has one line of texts spacing between the image and the text??

vuud

Quote from: farmerjeffe on March 07, 2007, 02:51:05 AM
Well it has one line of texts spacing between the image and the text??

It adds a <BR> to the img tag... Not sure if it does more than one though.  Does your HTML source show anything strange like that?
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco