문제

Hi, I want to redirect my page to another website, I used anchor tag but when I click on this it will add my website name also http://au.pricecomparereview.com/www.theiconic.com.au/Rococo-Textured-Mini-Skirt-113532.html

Please tell me about this . I am new in php I am using oscommerce

www.theiconic.com.au/Rococo-Textured-Mini-Skirt-113532.html

도움이 되었습니까?

해결책 2

If you want a PHP approach try this:

// Declare url variable
$url = "http://www.theiconic.com.au/Rococo-Textured-Mini-Skirt-113532.html";

// Use it to create the <a> with php
echo "<a href="$url" target="_blank">www.theiconic.com.au</a>";

Or with html use the PHP assing tags:

<a href="<?=$url ?>" target="_blank">www.theiconic.com.au</a>

다른 팁

use like this, you may be missing http://

<a href="http://www.theiconic.com.au/Rococo-Textured-Mini-Skirt-113532.html" target="_blank">www.theiconic.com.au</a>

I think your anchor tag would be like this presently:

<a href="www.theiconic.com.au/Rococo-Textured-Mini-Skirt-113532.html" target="_blank">www.theiconic.com.au</a>

Change it to

<a href="//www.theiconic.com.au/Rococo-Textured-Mini-Skirt-113532.html" target="_blank">www.theiconic.com.au</a>

and it will work fine.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top