PDA

View Full Version : Need help: GALLERIES HACK


kriskros
Jul-19-2008, 06:58 PM
I was able to run the slideshow on my homepage.

However, I cannot generate the galleries hack. Everytime I enter http://www.kriskrosphotography.com/galleries, it goes to my homepage.

I followed the codes I got from this site, dgrin.com.

Added this to footer javascript:
function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

if (hasPath("galleries"))
YD.addClass(document.body, "galleries");

and on CSS, entered the following:
.homepage #featuredBox {display:none;}
.galleries #categoriesBox {display:block !important;}

What seems to be the problem? Thanks guys.




Kris
www.kriskrosphotography.com (http://www.kriskrosphotography.com)
kriskros.smugmug.com

Allen
Jul-19-2008, 09:10 PM
I was able to run the slideshow on my homepage.

However, I cannot generate the galleries hack. Everytime I enter http://www.kriskrosphotography.com/galleries, it goes to my homepage.

I followed the codes I got from this site, dgrin.com.

Added this to footer javascript:
function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

if (hasPath("galleries"))
YD.addClass(document.body, "galleries");

and on CSS, entered the following:
.homepage #featuredBox {display:none;}
.galleries #categoriesBox {display:block !important;}

What seems to be the problem? Thanks guys.
Kris
www.kriskrosphotography.com (http://www.kriskrosphotography.com)
kriskros.smugmug.com
Remove this form your CSS, it goers in the javascript.

// fix the pesky pipes

YE.onAvailable("cobrand_footer", function() {this.innerHTML = this.innerHTML.replace(/\||what are feeds\?/gi, '');});

Add the # in front here.

#userBio {text-align: center !important;}

Remove the // here

//#bioBox .imgBorder {border: none;}

Remove the // and add /* and */ for comment tags.

/* //navigation hidden at the bottom of the page as well
- you just need to turn it on: */

/* // navbar */

/* // end of navbar */

This is not in your javascript. Add it there.

function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

if (hasPath("galleries"))
YD.addClass(document.body, "galleries");

You have this in your footer. Remove it because the above, if in your
javascript accomplishes it.

<script type="text/javascript">
function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

if (hasPath("galleries"))
YD.addClass(document.body, "galleries");
</script>

Make these changes to your CSS. I don't think your galleries/categories box
is active. Look in your control panel under the homepage tab and find it
there and click "show".

Remove these

.homepage #featuredBox {display:none;}

.galleries #categoriesBox {display:block !important;}

Add these

.homepage #galleriesBox,
.homepage #categoriesBox,
.homepage #featuredBox {
display: none;
}

.galleries #bioBox {
display: none;
}

.galleries #galleriesBox,
.galleries #categoriesBox,
.galleries #featuredBox {
display: block;
}

kriskros
Jul-19-2008, 09:33 PM
Remove this form your CSS, it goers in the javascript.

// fix the pesky pipes

YE.onAvailable("cobrand_footer", function() {this.innerHTML = this.innerHTML.replace(/\||what are feeds\?/gi, '');});
Add the # in front here.

#userBio {text-align: center !important;}

Remove the // here

//#bioBox .imgBorder {border: none;}

Remove the // and add /* and */ for comment tags.

/* //navigation hidden at the bottom of the page as well
- you just need to turn it on: */

/* // navbar */

/* // end of navbar */

This is not in your javascript. Add it there.

function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

if (hasPath("galleries"))
YD.addClass(document.body, "galleries");
You have this in your footer. Remove it because the above, if in your
javascript accomplishes it.

<script type="text/javascript">
function hasPath(sPath)
{
re = new RegExp("\/" + sPath + "(\/|$)");
return re.test(window.location)
}

if (hasPath("galleries"))
YD.addClass(document.body, "galleries");
</script>
Make these changes to your CSS. I don't think your galleries/categories box
is active. Look in your control panel under the homepage tab and find it
there and click "show".

Remove these

.homepage #featuredBox {display:none;}

.galleries #categoriesBox {display:block !important;}

Add these

.homepage #galleriesBox,
.homepage #categoriesBox,
.homepage #featuredBox {
display: none;
}

.galleries #bioBox {
display: none;
}

.galleries #galleriesBox,
.galleries #categoriesBox,
.galleries #featuredBox {
display: block;
}


Thanks Allen. Splendid job on the galleries hack. I was able to display an alternative galleries page.