Forums
View unanswered posts | View active topics It is currently Sat Jul 26, 2014 5:11 am



Reply to topic  [ 4 posts ] 
 PIE loading on front page, but not on subpages? 
Author Message

Joined: Thu May 17, 2012 6:08 am
Posts: 2
Post PIE loading on front page, but not on subpages?
Hi

I am using CSS3 PIE with OpenCart.

I have some buttons with the following CSS class:

Code:
a.greenbutton, input.greenbutton  {
    behavior: url("css3pie/PIE.php");
    -webkit-border-radius: 7px;
    -moz-border-radius: 7px;
    border-radius: 7px 7px 7px 7px; 
    cursor: pointer;
    display: inline-block;
    line-height: 11px;
    padding: 6px 12px;
    text-decoration: none;
    background-color: green;
    color: white;
    position:relative;
    z-index: 0;     
}


i changed PIE.htc to PIE.php because it was returning the wrong content type. Also, i added the following in my .htaccess file:
Code:
AddType text/x-component .htc
- there is probably no need for it now, since im using the .php file.

Furthermore, for PIE to work, i had to add following to the CSS class:

Code:
position:relative;
    z-index: 0;


The problem is, that PIE only renders the class on the front page, and not in subpages. Have a look at:

http://trashtalk.dk
and
http://trashtalk.dk/Apple/iPhone

the PIE files are placed in root/css3pie/

Where am i going wrong?
Thanks


Thu May 17, 2012 6:13 am
Profile

Joined: Wed Jul 14, 2010 11:46 am
Posts: 1441
Post Re: PIE loading on front page, but not on subpages?
See http://css3pie.com/documentation/known- ... tive-paths

If you use a relative path in the behavior's url, it will be resolved relative to the page's URL, not the URL of the stylesheet. So with your current value it would be resolved as http://trashtalk.dk/css3pie/PIE.php on the main page but http://trashtalk.dk/Apple/iPhone/css3pie/PIE.php on the interior page. Easiest for you is probably to make it domain-absolute by adding a leading slash.


Thu May 17, 2012 8:45 am
Profile

Joined: Thu May 17, 2012 6:08 am
Posts: 2
Post Re: PIE loading on front page, but not on subpages?
jason wrote:
Easiest for you is probably to make it domain-absolute by adding a leading slash.


Thanks for the feedback.

I edited it to:

Code:
behavior: url("/css3pie/PIE.php");


notice the leading slash. Was this what you meant?

It's still not working :(


Fri May 18, 2012 2:47 pm
Profile

Joined: Wed Jul 14, 2010 11:46 am
Posts: 1441
Post Re: PIE loading on front page, but not on subpages?
I don't understand what you're trying to apply it to. I find only two references to the behavior in your stylesheet, one on the body (which won't work) and one for a.greenbutton,input.greenbutton which doesn't seem to match anything in your page. The former is using a relative path to PIE.htc, and the latter is using behavior:url("//trashtalk.dk//css3pie/PIE.php") which is a bit wacky looking.


Fri May 18, 2012 3:04 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 4 posts ] 

Who is online

Users browsing this forum: Google [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.