FeralReason 0 Light Poster

As far as I am concerned, this thread seems solved if you attend to the following steps (all covered somewhere above). Please let me know if anyone disagrees:

1) Make sure session_start() is called before ANY other information is sent. Place it before any includes.
2) If this doesn't work, create a stripped down test file and test it again. If the stripped down test file does not work, try changing to a different encoding. In my environment "UTF-8 With BOM" DOES NOT WORK, while either "UTF-8 without BOM" or ANSI works fine.
3) If there is some reason (I can't think of one) to output something before calling session_start(), you might try putting ob_start() at the beginning of the file and ob_flush() at the end. This buffers the output and may allow session_start() to work -- but this is more of a work-around than a solution.
4) Using @session_start() does not solve the problem. It simply supresses the warnings so that you don't see them.

Does this solve the problem to everyone's satisfaction ?

FeralReason 0 Light Poster

Have you been using session_start() in someone of the included/required files?
Delete that row and then try again.

Edit:
I read the posts above again and went over something about XAMPP..
That webserver has never been more then problem for me, I'd recommend you to try another one.

VertrigoServ is very good and easy to modify/understand.

Once I got through the initial configuration (not hard with all of the online forum help) XAMPP has been great for me. I've been using it for over 2 years now.

FeralReason 0 Light Poster

I believe changing session_start() to @session_start() just suppresses the warning.

FeralReason 0 Light Poster

aldm,

I'm using notepad++ (great free editor), which has a tab called "Encoding". With this you just select an option to convert to whatever encoding you would like. By the way, ANSI seems to work too.

FeralReason 0 Light Poster

Nyight,

Yes this is valid.

The problem was that I was using UTF-8 WITH BOM and for some reason (in an XAMPP environment in Windows XP at least) this must be encoded in UTF-8 WITHOUT BOM.

I simply converted to this encoding (in notepad++) and the warning has disappeared.

But -- thanks for responding to post so quickly !!

FeralReason 0 Light Poster

I have the same problem and am sending no output before the session_start call.

I finally created a stripped down test file and STILL get the same problem.

My test file has ONLY this code:

<?php
$value = session_start();
echo "Session value = ".$value."<br>";
?>

As suggested in various sources:
1) There are no spaces, html, etc. preceding this.
2) The file is encoded in UTF-8 WITH BOM
3) I've modified my php.ini file to set: session.cache_limiter = public

But I still get these errors:

Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at C:\xampp\feralpots\eNorman\test.php:1) in C:\xampp\feralpots\eNorman\test.php on line 2

Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at C:\xampp\feralpots\eNorman\test.php:1) in C:\xampp\feralpots\eNorman\test.php on line 2
Session value = 1

I am baffled !

Does anyone know how to fix this ??

Thx !

FeralReason 0 Light Poster

At the moment I don't know. Just trying to prepare for a meeting with the client. So the options could be:
1) Different customers, with different logins, who will have access to the same folder, or
2) Different customers, with different logins, who will each have access to a folder specifically for them.
Info on either or both would help !

FeralReason 0 Light Poster

Not sure if this is the right place to post this. I've built a number of websites but have just now been asked to provide a password protected page that allows different customers FTP access to download files.

I feel dumb. Having never done anything like this before. Obviously I have to get an ftp account from the hosting provider (not me) but it would be great if someone could outline the dummies version (for me) for setting something like this up. Does this require multiple FTP accounts ? What could I expect from the host and what should I be providing ?

Thanx !

FeralReason 0 Light Poster

The following code works fine in IE8 and Firefox 3.5. Any idea why it does not work in Chrome ? Tried it both in localhost and on my web server -- no success.

In the header:

<?php
   if((isset($_COOKIE["unique_id"]))&&isset($_COOKIE["users_resolution"])){
      $screen_res = $_COOKIE["users_resolution"];
      $unique_id = $_COOKIE["unique_id"];
   }
   else //means cookie is not found set it using Javascript
   {
      ?>
<script language="javascript">
			<!--
			writeCookie();
			function writeCookie()
				{
				var today = new Date();
				var the_date = new Date("December 31, 2023");
				var the_cookie_date = the_date.toGMTString();
				var the_cookie = "users_resolution="+ screen.width +"x"+ screen.height;
				var the_cookie = "unique_id="+ uniqid();
				var the_cookie = the_cookie + ";expires=" + the_cookie_date;
				document.cookie=the_cookie
           			}
			function uniqid()
			  {
			  var newDate = new Date;
			  return newDate.getTime();
			  }
			//-->
		</script>
<?php } ?>

// And in the ,body>

         <?php
	echo "Screen resolution: ".$screen_res."<br>";
	echo "Unique ID: ".$unique_id."<br>";
	?>

Any help would be appreciated.

FeralReason 0 Light Poster

I'm looking to put a context-free feedback form on my site (link placed in my navbar) that would cause a small window to pop-up, allow the user to enter feedback and submit. On submit, the window would disapear and the user would remain on the page they were previously on. I'm predominately a PHP / MySql programmer but suspect this may be better done in Javascript or something else. Can anyone steer me towards useful info or links on how I might do this ?

FeralReason 0 Light Poster

An extremely simple example that relies on the "title" for an anchor tag is shown below. Perhaps this can take you in the right direction.

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
        "http://www.w3.org/TR/html4/strict.dtd">
<HTML>
<HEAD>
<TITLE>Help Example</TITLE>
<style type="text/css">
	img
	{  
		border-style: none;
	}
</style>
<body>
		<div>
			<a href="#" title="A description for this first item."><img src="/images/QuestionMark.gif" style="vertical-align: middle;"></a>
			<span style="vertical-align: middle; padding-left:10px;">Text 1.</span>
		</div>
		<div>
			<a href="#" title="Another description for this second item."><img src="/images/QuestionMark.gif" style="vertical-align: middle;"></a>
			<span style="vertical-align: middle; padding-left:10px;">Text 2.</span>
		</div>
</BODY>
</HTML>
FeralReason 0 Light Poster

1) Remove the "float:right" from the sub_content div to get it to fill the width of the internal_content div.
2) Add a "float:right" to the trace_details list to get this to position properly (which you have as an ID and should change to a class as previously mentioned.) I'm assuming this is the div containing the "location, reader, rating, etc." content.
3) When I do this, I still see that the divs contained by the sub_content div flow outside of aub_content boundaries (not sure if you see this with the content present and whatever DOCTYPE you are using.) Adding an "overflow:auto" to the sub_content div keeps these contained divs from flowing outside of the box.

Here is modified code. Took out the images and substituted background colors & labeled the divs so that the whole thing is easier to see.

Let me know if this helps.

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
        "http://www.w3.org/TR/html4/strict.dtd">
<HTML>
<!-- http://www.daniweb.com/forums/thread200673.html -->

<HEAD>
<STYLE type="text/css">

.content{
	border-style:solid;
	border-width:1px;
	border-color:022c82;
	margin-left:1%;
	margin-bottom:10px;
	padding-bottom:10px;
	background-color:white;
}
.internal_content{
	width:98%;
	padding:10px;
	background-color:yellow;
}
.sub_header{
	width:100%;
	background-color:red;
	/* background-image:url(/images/sub_header.gif); */
	height:30px;
}
.sub_footer{
    width:100%;
	background-color:blue;
	/* background-image:url(/images/sub_header.gif); */
	height:30px; 
    clear:both;
}
.sub_content{
	border-style:none solid none solid;
	border-width:1px;
	border-color:bebeff;
	background-color:green;
	padding:5px;
	height:auto;
	overflow:auto;
}
.book_details{
	width:35%;
    float:left;
    clear:left;
	background-color:gray;
}
.trace_details{
	width:65%;
	min-width:300;
	background-color:orange;
	float:right;
}

</style>
</HEAD>
<BODY>
<div class="content">
	<div class="content_header"><h2 class="header_text">content_header</h2></div>
	<div class="nav">nav
	       <!-- nav bar stuff -->
	</div>
        <div class="internal_content">internal_content
	     <div class="sub_header rounded_top"><h2 class="sub_header_text">sub_header_text</h2></div>
		<div class="sub_content">sub_content
			<div class="book_details">book_details …
FeralReason 0 Light Poster

Can you either post some code or a URL ? Would make it easier for me to understand what you are describing.

FeralReason 0 Light Poster

Very good! Never heard of quirks mode but (after a short search for my education) this certainly explains the problem. (http://www.quirksmode.org/css/quirksmode.html - section on overflow:visible)

Thanx for the advice !

FeralReason 0 Light Poster

I have checked your code. The problem is with the positiong of floated div's in a nested div. Please add these css:-

.Row{
margin:3px 3px 3px 3px;
[B]clear: both;[/B]
}


.Cell {
    color:#000000;
        border:1px solid #CCCCCC;
        float:left;
        font-size:16px;
        text-align:center;
        width:49%;
                   [B]margin-right:3px;[/B] }

I hope this will help you and for detailed explanation please go through this site:
http://www.positioniseverything.net/easyclearing.html

Thanks much for your replay. When I add the "clear:both" line the lower edge of the container moves down to contain the first row but not the second. Adding the "margin-right:3px" statement causes all 4 cells to stack vertically rather than appear 2 to a row horizontally. However, your reference was golden !

The reference has a link to a more recent article on this problem, offering up several solutions. The most elegant is to place an "overflow:auto" in the container. This works perfectly without any other changes.

One other solution that came from my son in San Francisco is to simple set the height of the row. Apparently floating the cells causes the container to lose track of the height of what it is enclosing.

All-in-all: "overflow:auto" seems to be the best solution.

Thanx much.

FeralReason 0 Light Poster

HTML tables are used for displaying tabular data on the page.
Div's are used to build the entire layout of the page. It gives more layout control using CSS.

And i dont see any thing wrong with your above code and it works fine with my browser . But i recommend you should use Html tables itself as you want just tabluar data.

Thanx for the reply. I understand (and actually agree with) the argument but (call it self-education) I am still interested in determining to what extent css can do tables without using table tags.

In the code shown, the background should be yellow -- showing that the TblContainer div is in fact containing everything. It only shows up as a yellow band at the top of the cells in IE, FF and Chrome when I load it -- unless I delete the DOCTYPE. Are you seeing something different ?

Thanx for your help.

FeralReason 0 Light Poster

Admittedly, I'm new to CSS but I am having some difficulty converting tables to CSS. Here is a CSS example for a simple 4 cell table that works fine -- but only without the DOCTYPE declaration (any DOCTYPE declaration)!

Does anyone know what, if anything, I am doing wrong ? Any help would be appreciated.

(Also I would like to see any successful examples anyone would like to post.)

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>
<head>
<style type="text/css">
	.TblContainer {
		width:400px;
		font-family:Arial,Helvetica,sans-serif;
		background-color:yellow; 
		border:1px solid #CCCCCC;
		margin:3px 3px 3px 3px;
	}
	
	.Row {
		margin:3px 3px 3px 3px;
	}
	
	.Cell {
		color:#000000;
		border:1px solid #CCCCCC;
		float:left;
		font-size:16px;
		text-align:center;
		width:49%;
	}
</style>
</head>
<body>
<div class="TblContainer">
	<div class="Row">
		<div class="Cell">Cell 1</div>
		<div class="Cell">Cell 2</div>
	</div>
	<div class="Row">
		<div class="Cell">Cell 3</div>
		<div class="Cell">Cell 4</div>
	</div>
</div>  
</body>
</html>
FeralReason 0 Light Poster

I got a copy from my local library. If yours does not have it, they can likely order it from some other library. Amazon has it online. However, there are SO many books in this category (good and bad) that I prefer using them a bit before I actually buy them.

FeralReason 0 Light Poster

Yes, thanks -- although I did not know this 11 days ago. Only the code posted in 2008 by Schwartznavy used filters.blendTrans. I don't think any of the others mentioned here use this.

The link Schwartznavy provided 3 days ago (http://www.gerd-tentler.de/tools/) does use ".opacity". The guy who wrote this code (Gerry) has now explained to me how to make the transitions visible (my system was too fast and I wasn't seeing them.) Essential's code uses ".opacity". The code I am currently using (from brainerror.com) also uses ".opacity".

I have something working right now and may switch to the latest schwartznavy solution (http://www.gerd-tentler.de/tools/) when I have hit the rest of my deadlines. Will still test Essential's code as he modifies it. However, as the the Mexican Bandits said in the "Undefeated", "We are so poor (at Javascript) and you have so much (knowledge of how to do this stuff) we'll take everything (that you are willing to offer) !" So feel free to do a short tutorial. Nice to have so rich a thread going.

Thanx, Glenn

FeralReason 0 Light Poster

Hi there,

Did you fix everything up?

- i'll get back on this one as soon as i get my new pc.

Kind regards...
essential

Without the ability to set a watch so I can understand how that variable is changing and whether the problem is caused by rounding to zero or whatever, I'm not quite comfortable with diving in and modifying your code (I'm not a Javascript programmer -- at least not yet. Got my hands full with PHP and MySql.)

Ciao, Glenn

FeralReason 0 Light Poster

Thanks for the comment. If you're dad is up to it, he should visit our Facebook page -- the link is on our main web site www.c7f.navy.mil.

Addendum to last post -- After reviewing Gerry's content.js (for the first time) it seems fairly clear how to do titles and hyperlinks. I wrote Gerry about the lack of Fades in FF 3.0.10.

FeralReason 0 Light Poster

Will do. You must have done quite a bit of work on this slideshow. Gerry's version does not do fade transitions in FF, have titles, clickthroughs, etc. Is the c7f version posted anywhere ?

Thanx, Glenn.

FeralReason 0 Light Poster

Thanks much. I like it - labels, click-throughs, transitions (that work in FF), with both image-rotation and a little next/previous/pause device. I'll try this one out !

On a side note, noticed the June 3rd Yokosuka slide in the slideshow and forwarded the link to my Father, who was on board the USS Wilkesbarre and was involved with securing the Yokusuka naval base immediately before Japan signed the surrender terms on 9/2/45.

You must be Navy. Thanks again !

FeralReason 0 Light Poster

One more point, when this code:

else if ( browser.toLowerCase().indexOf("firefox") !== -1 ) {
      imgRotate.style.MozOpacity = Math.round( j / 100 ); 
      }

is changed to this:

else if ( browser.toLowerCase().indexOf("firefox") !== -1 ) {
      imgRotate.style.MozOpacity = 5;
      }

All images become visible in Firefox (only). I couldn't figure out how to set a watch on the j variable but that is what I would look at first, if you can do that from your handheld. :-)

FeralReason 0 Light Poster

Same result as before. Titles show but images do not. In firebug I can see that we are looping through images correctly and the images are in the right path (hovering over the path shows a thumbnail of the image.) However, I noticed that as we loop through the images, opacity is always 0. Here is code I copied directly from firebug.

<div id="box">
<img id="slidePic" alt="Image Slide" src="http://localhost/images/image4.jpg" style="opacity: 0;"/>
<div id="slideText">Text Sample #5</div>
</div>
FeralReason 0 Light Poster

google javascript+slideshow+with+captions+and+crossfade
or if you dont need the slideshow to be clientside
google php+slideshow+with+captions+and+crossfade
google asp+slideshow+with+captions+and+crossfade

Thanks, I will ! It does seem like it should be possible to adapt PHP / CSS gallery code (which I've already developed) to do a slideshow but (being fairly new at this) I didn't see anyway to do fade-blends without javascript so I didn't investigate that path.

FeralReason 0 Light Poster

I'm impressed. Developing on a handheld must be challenging !

Handling cross-browser transitions seems to be the big challenge with slideshows. Of the 30 or so sites I have reviewed that are competing with my client (my wife), about 7 have slideshows. 2 of those are done with Shockwave Flash (which of course satisfies all of my requirements except cost). Of the others none have captions, none are hyperlinked (so that you can click on the image and go somewhere where you can buy the product) and only one seems to have a cross-browser fade/blend working (although others have fade/blend working in IE only.) I've worked through the strange side effects in the brainerror.net code and it is working ok now but I am still without captions and hyperlinks (which my wife is really pushing for !) ... good for my education tho... :-)

FeralReason 0 Light Poster

(Hopefully I am not duplicating a reply -- looked like I timed out before I could submit last time.)

I created the images -- image0.jpg through image4.jpg in my images directory and modified the path so that they could be accessed, then tried your code in both IE8 and FF.

In both, I can see that the tube div is being displayed (I added color:red to the style so that I could see the border.) Under this I see the captions, so I know we are looping properly. In firebug I can see that the image paths are being constructed properly. However, I am seeing no images.

I am currently using code from brainerror.com -- seems to give me the cross-browser fade-transitions I need even though it does not display captions. But I'm happy to test whatever else you come up. (Also happy to share the code I am using if you want to see it.)

Thanx !


I'm still not sure for the end result of this script, but if you find any promblem, just let me know again...

<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head profile="http://www.w3.org/2005/10/profile">
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="Content-Style-Type" content="text/css" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
<title>Image Cross Fader Script with Text Rotator</title>
<style type="text/css">
/* <![CDATA[ */
* { border : none; }
html, body { …
FeralReason 0 Light Poster

I'll try to make another update later...

Can you provide a short detail, regarding the issue in IE8?

Thanks...

In IE8, image1.jpg displays (with caption) followed immediately by 1.jpg (with caption) and then nothing else happens. (I am using your image names for convenience.) There are no cross-fade transitions between the two images (but I also don't get these transitions in FF and Chrome.)

Thanx for your help !

FeralReason 0 Light Poster

Further thoughts .. I am very new to javascript (more familiar with PHP and CSS.) Ultimately, I want a cross-browser slideshow, with titles and hyperlinks, and cross-fade effects that work across browsers. (Additionally, I want it to be flexible enough so that I can eventually select the images and text from a database.)

Summarizing where I am at :
1) schwarznavy's 4/2/08 post executes a slideshow in Chrome, FF and IE8, without text but with a cross-fade effect that only works in IE.
2) essential's 5/31/09 post executes a slideshow in Chrome and Firefox but not in IE8, with text but shows no cross-fade effect in either browser.
3) http://brainerror.net/scripts/javascript/blendtrans/demo.html's code (8/18/07) executes a slideshow in Chrome, Firefox and IE8, without text but with nice cross-fade effects that work in all 3 browsers. (But doesn't center images and I get strange side effects when I try to do this with css.)

Has anyone seen code that executes a slideshow A) cross-browser with cross-browser cross-fade effects, B) with text captions and (optionally) C) with hyperlinks?

FeralReason 0 Light Poster

Thanks much ! I do appreciate it. This works flawlessly in Chrome and Firefox. Couldn't get it to work in IE8. (I realize this code dates to well before IE8.)

Thanx again.

FeralReason 0 Light Poster

Too bad no one ever replied to this ! I am trying to solve exactly the same problem with exactly the same code. (The 2nd problem I am trying to solve is to get this fade/blend transition to work in non-IE browsers.) If you have solved your problem would you be willing to post your code ?