Home arrow Forum Input box, Help
  Welcome, Guest. Please login or register.
Did you miss your activation email?
December 02, 2008, 08:56:12 PM
Home New Posts Search Calendar


Login with username, password and session length
+  Joomla Forum
|-+  General Discussion
| |-+  Techies Zone (Moderator: johnny)
| | |-+  Input box, Help
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: Input box, Help  (Read 3069 times)
aravot
Joomla Pro
**

Karma: +0/-2
Offline Offline

Posts: 89


test/test


View Profile WWW
Input box, Help
« on: April 23, 2005, 12:56:50 AM »

I am trying to create a input box where a user would write his/here website address once saved the address would be displayed with an appended code.

input box
Code:
<param name="link" type="text" default="" label="Link" description="URL to Galler2 folder" />

-----------
get address
Code:
$link = $params->get( 'link' );

      echo "<a href=" . $link . "main.php?g2_view=imageblock:External&g2_blocks=randomImage";

?>

example;
user write this http://www.mywebsite.com


displayed this http://www.mywebsite.com/main.php?g2_view=imageblock:External&g2_blocks=randomImage

Thanks
Logged
Editor (cowboy)
Administrator
Joomla Guru
*****

Karma: +86/-23
Offline Offline

Posts: 1144



View Profile WWW
Re: Input box, Help
« Reply #1 on: April 26, 2005, 10:26:32 AM »

all looks fine, except here...

Code:
<?php
$link 
$params->get'link' );
$link =  $link."/main.php?g2_view=imageblock:External&g2_blocks=randomImage";
?>

<a href="<?php echo $link?>">text</a>
Logged
aravot
Joomla Pro
**

Karma: +0/-2
Offline Offline

Posts: 89


test/test


View Profile WWW
Re: Input box, Help
« Reply #2 on: April 26, 2005, 03:07:44 PM »

all looks fine, except here...

Code:
<?php
$link 
$params->get'link' );
$link =  $link."/main.php?g2_view=imageblock:External&g2_blocks=randomImage";
?>

<a href="<?php echo $link?>">text</a>

Thank you, but instead of displaying 'text' I want to display output of the link which should be an image from gallery
Logged
aravot
Joomla Pro
**

Karma: +0/-2
Offline Offline

Posts: 89


test/test


View Profile WWW
Re: Input box, Help
« Reply #3 on: April 27, 2005, 03:01:10 PM »

Finally got it to work.

Code:
<?php

defined
'_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' );

$link $params->get'link' );
$link =  $link."/main.php?g2_view=imageblock:External&g2_blocks=randomImage";
@
readfile($link)
?>
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  



Login with username, password and session length

Powered by MySQL Powered by PHP Joomla Forum | Powered by SMF 1.1 RC1.
© 2001-2005, Lewis Media. All Rights Reserved.
Joomla Bridge by JoomlaHacks.com
Valid XHTML 1.0! Valid CSS!

Joomla Hacks is a Joomla Components, Joomla Modules, Joomla Templates, & Joomla Mambots resource portal. None of the text or images in this public website may be copied without the expressed written consent of the authors. Copyright 2005 by JoomlaHacks.com. Powered by Joomla. All rights reserved.
Terms of Use
Joomla Hacks



Joomla Hacks
German Lang French Lang Italian Lang Spanish Lang Japanese Lang Chinese Lang
Search Contact About Advertise Blogs Topsites Submit News Register Login