phplayers bug in .9

Talk about writing modules and plugins for CMS Made Simple, or about specific core functionality. This board is for PHP programmers that are contributing to CMSMS not for site developers
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

In .9 and .9rc4 (maybe earlier... not sure) but definitely not 8.2.

phplayers css is called 4 times. I always move the css from the layersmenu-cms.css to the css management and I replace it with /* moved to css manager */

I first noticed before I moved it out of the file because no matter how I changed the css in an inline css editor in firefox (it lets you change the css of any page so you can see the result... then I copy the changes and put them in the file/database) the changes would show up.

That is when I noticed that if I scroll down far enough then I get to .horbar again... then I scrolled down again and .horbar again.

I believe it was being called in .9rc4 3 times (if memory serves me) and then I just installed .9 and it is now called 4 times. here is what my css looks like now.


/stylesheet.php?templateid=4

Code: Select all

/* moved to css manager */
/* moved to css manager */
/* moved to css manager */
/* moved to css manager */

body, p, td, span, form, input {
	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
}
a:link, a:visited, a:active	{
	color: #0586bd;
	text-decoration: none;
}
a:hover{
	text-decoration: underline;
}

p {
	line-height: 1.5em;
}
.BodyBox {
	border-right-width: 1px;
	border-left-width: 1px;
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-right-color: #D7D7D7;
	border-left-color: #D7D7D7;
	border-bottom-color: #D7D7D7;
}
.BodyBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.header {
	font-weight: bold;
	font-size: 16px;
	color: #123E9F;
	background-image:  url("/images/template/bullet_new.gif");
	background-repeat: no-repeat;
	text-indent: 25px;
}
.featuredcourses a:link, .featuredcourses a:visited, .featuredcourses a:active {
	color: #0586BD;
	text-decoration: none;
	}
.featuredcourses {
	color: #0586BD;
	text-decoration: none;
	font-size: 12px;
	background-image:  url("/images/template/bullet_arrow.gif");
	background-repeat: no-repeat;
	text-indent: 25px;
	font-weight: bold;
}
.date {
	font-weight: bold;
}
.location {
	font-weight: bold;
}
.copyright {
	font-size: .66em;
	color: #FFFFFF;
}

.LeftBox {
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: none;
	border-bottom-style: solid;
	border-left-style: none;
	border-bottom-color: #D7D7D7;
}
.LeftBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.LeftBox p.leftbox {
	font-weight: bold;
	font-size: 1.15em;
	color: #123E9F;
}
.RightBox {
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: none;
	border-bottom-style: solid;
	border-left-style: none;
	border-bottom-color: #D7D7D7;
}
.RightBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.RightBox p.rightbox {
	font-weight: bold;
	font-size: 1.15em;
	color: #123E9F;
}
.footer (line 22)
{
    font-family: Helvetica,Verdana,Arial,sans-serif;
    color: rgb(0, 0, 0);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.75em;
}

.footer:hover    (line 19)
{
    color: rgb(17, 62, 155);
}

.horbar {
	color: black;
	background-color: #FFFFE4;
	/*border: 2px outset #cecac1;*/
}
.horbaritem {
	float: left;
	white-space: nowrap;
	font-family: verdana, geneva, arial, helvetica, sans-serif;
	font-size: 13px;
	font-weight: bold;
}
.horbaritem a {
	display: block;
	text-decoration: none;
}
.horbaritem a:link {
	color: #000000;
	text-decoration: none;
}
.horbaritem a:visited {
	color: #000000;
	text-decoration: none;
}
.horbaritem a:hover {
	color: #ffffff;
	background-color: #4b6983;
	text-decoration: none;
}
.horbaritem a:active {
	color: #ff0000;
	text-decoration: none;
}

.verbar	{
	color: black;
	background-color: #EDF2F5;
}

.submenu	{
	position: absolute;
	left: 0;
	top: 0;
	visibility: hidden;
}

.subframe	{
	position: relative;
	display: block;
	background-color: #EDF2F5;
	border: 1px solid #64879d;
}

.item	{
	padding: 3px;
	text-align: left;
	white-space: nowrap;
}

.separator	{
	background-color: #ff0000;
	border-top: 1px solid #9e9a91;
	border-bottom: 1px solid #ffffff;
	margin: 2px 1px 2px 1px;    /* top right bottom left */
	height: 0;
	font-size: 1px;
	line-height: 0
}

.item a	{
	position: relative;
	display: block;
	text-decoration: none;
}

.item a:link	{
	color: #000000;
	text-decoration: none;
}

.item a:visited	{
	color: #000000;
	text-decoration: none;
}

.item a:hover	{
	color: #ffffff;
	background-color: #4b6983;
	text-decoration: none;
}

.item a:active	{
	color: #ff0000;
	text-decoration: none;
}

.item .fwdarr	{
	position: absolute;
	top: 5px;
	right: 7px;
}
Perhaps with each RC something got duped?

I can't reproduce it in IE because I can't go to the /stylesheet.php... directly.
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

I did that before when I first started out. I realized I was each time adding another of the line at the top... however that is not what is happening now. I wish that was all it was.

The site is running on a local server (trying out wamp), otherwise I would send you a link.

here is my css style in css management called phplayers.

Code: Select all

.horbar {
	color: black;
	padding-left: 10px;
	/*background-color: ;*/
	/*border: 2px outset #cecac1;*/
}
.horbaritem {
	float: left;
	white-space: nowrap;
	font-family: Helvetica, Verdana, Arial, sans-serif;
	text-transform: uppercase;
	font-size: 12px;
	font-weight: bold;
}
.horbaritem a {
	display: block;
	text-decoration: none;
}
.horbaritem a:link {
	color: #000000;
	text-decoration: none;
}
.horbaritem a:visited {
	color: #000000;
	text-decoration: none;
}
.horbaritem a:hover {
	color: #000000;
	/*background-color: #4b6983;*/
	text-decoration: none;
}
.horbaritem a:active {
	color: #ff0000;
	text-decoration: none;
}

.verbar	{
	color: black;
	background-color: #EDF2F5;
}

.submenu	{
	position: absolute;
	left: 0;
	top: 0;
	visibility: hidden;
}

.subframe	{
	position: relative;
	display: block;
	background-color: #009f81;
	border: 1px solid #000000;
}

.item	{
	padding: 3px;
	text-align: left;
	white-space: nowrap;
}

.separator	{
	background-color: #ff0000;
	border-top: 1px solid #9e9a91;
	border-bottom: 1px solid #ffffff;
	margin: 2px 1px 2px 1px;    /* top right bottom left */
	height: 0;
	font-size: 1px;
	line-height: 0
}

.item a	{
	position: relative;
	display: block;
	text-decoration: none;
}

.item a:link	{
	color: #ffffff;
	text-decoration: none;
}

.item a:visited	{
	color: #ffffff;
	text-decoration: none;
}

.item a:hover	{
	color: #000000;
	background-color: #d6d6d6;
	text-decoration: none;
}

.item a:active	{
	color: #ffffff;
	text-decoration: none;
}

.item .fwdarr	{
	position: absolute;
	top: 5px;
	right: 7px;
}
Now, here is the content of the file in the modules folder for phplayers.

Code: Select all

/* moved to css manager */
Now here is the result from the web developer toolbar where I see the CSS.

Code: Select all

/* moved to css manager */
/* moved to css manager */
/* moved to css manager */
/* moved to css manager */

body, p, td, span, form, input {
	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
}
a:link, a:visited, a:active	{
	color: #0586bd;
	text-decoration: none;
}
a:hover{
	text-decoration: underline;
}

p {
	line-height: 1.5em;
}
.BodyBox {
	border-right-width: 1px;
	border-left-width: 1px;
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-right-color: #D7D7D7;
	border-left-color: #D7D7D7;
	border-bottom-color: #D7D7D7;
}
.BodyBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.header {
	font-weight: bold;
	font-size: 16px;
	color: #123E9F;
	background-image:  url("/images/template/bullet_new.gif");
	background-repeat: no-repeat;
	text-indent: 25px;
}
.featuredcourses a:link, .featuredcourses a:visited, .featuredcourses a:active {
	color: #0586BD;
	text-decoration: none;
	}
.featuredcourses {
	color: #0586BD;
	text-decoration: none;
	font-size: 12px;
	background-image:  url("/images/template/bullet_arrow.gif");
	background-repeat: no-repeat;
	text-indent: 25px;
	font-weight: bold;
}
.date {
	font-weight: bold;
}
.location {
	font-weight: bold;
}
.copyright {
	font-size: .66em;
	color: #FFFFFF;
}

.LeftBox {
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: none;
	border-bottom-style: solid;
	border-left-style: none;
	border-bottom-color: #D7D7D7;
}
.LeftBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.LeftBox p.leftbox {
	font-weight: bold;
	font-size: 1.15em;
	color: #123E9F;
}
.RightBox {
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: none;
	border-bottom-style: solid;
	border-left-style: none;
	border-bottom-color: #D7D7D7;
}
.RightBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.RightBox p.rightbox {
	font-weight: bold;
	font-size: 1.15em;
	color: #123E9F;
}
.footer (line 22)
{
    font-family: Helvetica,Verdana,Arial,sans-serif;
    color: rgb(0, 0, 0);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.75em;
}

.footer:hover    (line 19)
{
    color: rgb(17, 62, 155);
}

.horbar {
	color: black;
	padding-left: 10px;
	/*background-color: ;*/
	/*border: 2px outset #cecac1;*/
}
.horbaritem {
	float: left;
	white-space: nowrap;
	font-family: Helvetica, Verdana, Arial, sans-serif;
	text-transform: uppercase;
	font-size: 12px;
	font-weight: bold;
}
.horbaritem a {
	display: block;
	text-decoration: none;
}
.horbaritem a:link {
	color: #000000;
	text-decoration: none;
}
.horbaritem a:visited {
	color: #000000;
	text-decoration: none;
}
.horbaritem a:hover {
	color: #000000;
	/*background-color: #4b6983;*/
	text-decoration: none;
}
.horbaritem a:active {
	color: #ff0000;
	text-decoration: none;
}

.verbar	{
	color: black;
	background-color: #EDF2F5;
}

.submenu	{
	position: absolute;
	left: 0;
	top: 0;
	visibility: hidden;
}

.subframe	{
	position: relative;
	display: block;
	background-color: #009f81;
	border: 1px solid #000000;
}

.item	{
	padding: 3px;
	text-align: left;
	white-space: nowrap;
}

.separator	{
	background-color: #ff0000;
	border-top: 1px solid #9e9a91;
	border-bottom: 1px solid #ffffff;
	margin: 2px 1px 2px 1px;    /* top right bottom left */
	height: 0;
	font-size: 1px;
	line-height: 0
}

.item a	{
	position: relative;
	display: block;
	text-decoration: none;
}

.item a:link	{
	color: #ffffff;
	text-decoration: none;
}

.item a:visited	{
	color: #ffffff;
	text-decoration: none;
}

.item a:hover	{
	color: #000000;
	background-color: #d6d6d6;
	text-decoration: none;
}

.item a:active	{
	color: #ffffff;
	text-decoration: none;
}

.item .fwdarr	{
	position: absolute;
	top: 5px;
	right: 7px;
}
I checked in the templates... no css. I checked in the default css in cssmanager and no /* blah blah */ and the same with the phplayers css style.

I have closed my browser, flushed the cache and refreshed the page. It still puts the commented out file in there 4 times.
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

edit---
I am going to bed... my eyes are crossing. Thanks. I will follow up in the morning.


original message---

here is my default one (actually called main... my bad)
It isnt here either.

I also tested another .9 install I just did since posting this message. It also calls the phplayers file multiple times.

I don't think it is my test server because I have a site with mircoweb and one with wampserver.

Code: Select all

body, p, td, span, form, input {
	font-family: Tahoma, Verdana, Arial, Helvetica, sans-serif;
	font-size: 12px;
}
a:link, a:visited, a:active	{
	color: #0586bd;
	text-decoration: none;
}
a:hover{
	text-decoration: underline;
}

p {
	line-height: 1.5em;


}
.BodyBox {
	border-right-width: 1px;
	border-left-width: 1px;
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: solid;
	border-bottom-style: solid;
	border-left-style: solid;
	border-right-color: #D7D7D7;
	border-left-color: #D7D7D7;
	border-bottom-color: #D7D7D7;
}
.BodyBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.header {
	font-weight: bold;
	font-size: 16px;
	color: #123E9F;
	background-image:  url("/images/template/bullet_new.gif");
	background-repeat: no-repeat;
	text-indent: 25px;
}
.featuredcourses a:link, .featuredcourses a:visited, .featuredcourses a:active {
	color: #0586BD;
	text-decoration: none;
	}
.featuredcourses {
	color: #0586BD;
	text-decoration: none;
	font-size: 12px;
	background-image:  url("/images/template/bullet_arrow.gif");
	background-repeat: no-repeat;
	text-indent: 25px;
	font-weight: bold;
}
.date {
	font-weight: bold;
}
.location {
	font-weight: bold;
}
.copyright {
	font-size: .66em;
	color: #FFFFFF;
}

.LeftBox {
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: none;
	border-bottom-style: solid;
	border-left-style: none;
	border-bottom-color: #D7D7D7;
}
.LeftBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.LeftBox p.leftbox {
	font-weight: bold;
	font-size: 1.15em;
	color: #123E9F;
}
.RightBox {
	border-bottom-width: 1px;
	border-top-style: none;
	border-right-style: none;
	border-bottom-style: solid;
	border-left-style: none;
	border-bottom-color: #D7D7D7;
}
.RightBox div {
	padding-left: 25px;
	padding-bottom: 10px;
	padding-right: 20px;
}
.RightBox p.rightbox {
	font-weight: bold;
	font-size: 1.15em;
	color: #123E9F;
}
.footer (line 22)
{
    font-family: Helvetica,Verdana,Arial,sans-serif;
    color: rgb(0, 0, 0);
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.75em;
}

.footer:hover    (line 19)
{
    color: rgb(17, 62, 155);
}
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

phplayers bug in .9

Post by Greg »

Instead of making all those changes just do it this way. :wink:

Go here
Greg
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

I am with patricia. Move it out of the file and then you can use the css manager as it was intended. I think the css manager is one of the best featrues. A great way to seperate content from code.
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

phplayers bug in .9

Post by Greg »

I agree JP and Pat. If it wasn't there I wouldn't need a workaround.
One of the most confusing things for the new user of this CMS.
Greg
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

I am just glad I am not crazy!

So... any idea why the file is being called so many times?
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

So, does anyone have any idea what is causing this? I can live with it because I move the css out of the file anyway. Just cusious.
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

phplayers bug in .9

Post by Greg »

Just a note, I have an extension to list style sheets on a right click for IE and the PHPLayers CSS is loaded multiple times in IE as well.

Server logs on 3 websites running 0.9.2 all show stylesheet.php as the file being accessed the most.
Greg
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

Greg wrote:Just a note, I have an extension to list style sheets on a right click for IE and the PHPLayers CSS is loaded multiple times in IE as well.

Server logs on 3 websites running 0.9.2 all show stylesheet.php as the file being accessed the most.
Give me a link to that extension for seeing the stylesheets on IE, if you could.

Thanks for testing it on IE. I would hate to have made a big stink about a Firefox only bug, even though that is my main browser.
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

phplayers bug in .9

Post by Ted »

I'll try to debug this this afternoon. I have a way to figure out what it calling and should be able to trace it. I'll post the results and/or fix.
Greg
Power Poster
Power Poster
Posts: 598
Joined: Sun Sep 26, 2004 6:15 pm

phplayers bug in .9

Post by Greg »

JP you can get the StyleSheet Browser here CSS Stylesheet Browser
Greg
jptechnical
Forum Members
Forum Members
Posts: 131
Joined: Wed Jan 12, 2005 12:18 am

phplayers bug in .9

Post by jptechnical »

Thanks Greg, I like!
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: phplayers bug in .9

Post by Ted »

I have exorcised the demons!

It's such a stupidly simple bug, that I can't believe I didn't find it earlier.  Basically, I was calling the same loop twice, so it was displaying it for EACH module that was installed and active.

If you want to fix this now, edit stylesheet.php and remove one of the 2 foreach lines (doesn't matter which), the { below it, and it's corrosponding } below.  That will fix it.
Post Reply

Return to “Developers Discussion”