almostbob 866 Retired: passive income ROCKS

I have done some testing and the SRC I inserted for the font is just a standard .ttf (Truetype Font) file (If you open it directly in your browser it downloads as a file called font.ttf)

what you download and get in your browser has nothing to do with what the server is able to do with it, and whther the file is called as a download url or as a linked css file may effect the processing applied by the server.
thats what php perl asp python are for.

samarudge commented: Helpful as always +3
almostbob 866 Retired: passive income ROCKS

Yes I understand CSS3 isn't complete, however my first code snippet WORKS in ALL 4 major browsers, however when I load the font from my own server with the exact same code it doesn't work.

sorry bloke was posting and thinking at the same time, took a bit to find the link was looking for, retry the above post

almostbob 866 Retired: passive income ROCKS

font selection is css3.
CSS3 is not complete and only partially implemented,
no browser yet released supports all of css3 and what support there is is buggy as the standard is not complete
absolutely pointless to include something that will NOT work in 90%+ browsers, so google have on the helpscreens of their site how to make non-css3 browsers act like they know whats going on
http://code.google.com/apis/webfonts/docs/webfont_loader.html#Example

The WebFont Loader is served through the Google AJAX Libraries API.

It provides events that are fired at different stages of the loading of the fonts. You can either write code to react to those events, or use CSS styles defined by the library to automatically make styles change when fonts have finished loading

EDIT:: would (probably) be better to access the files off the google repositoroy, than your server,
their (Google) server farm is spread all over the world and is way faster than your server. gets you the advantage of multi-sourcing the http protocol allows only two files from each domain to parallel, but can stream 2 files from three domains (=6) at the same time.
Other sites are likely to be using the same file from google, if not now, in the near fuure, the browser may find the css already in the user tif and not dl it.

almostbob 866 Retired: passive income ROCKS

look at the documentation for .htaccess mod_rewrite for your apache server
it is easy in .htaccess to change the displayed url of /mysite.com/profile.php?user=XXX to /mysite/profiles/XXX.html (or anything else)
everyony can see /profiles/ben.html
but session/login set that only someone properly logging in as Ben can modify /profiles/ben.html
there is no requirement for any personalised pages to actually exist, my site has 1600 pages in google,
=> 15scripts 2db and 307folders full of vid + images (BLOB take too long) make those pages, (several thousand pages that arent different enough to get indexed)
-none of the pages exist

all database, queries create the page on the fly in a php template, output to the browser as .html,
updates to allow the user to make LIMITED modification to their own details
there is definitely no requrement to copy anything on the server, not the approach used anywhere

your profile page here on DaniWeb likely does not exist either, its likely to be profile.php pulling your details from the database

perhaps a bit long for the reply, but its a shitload easier to build it right, when you design the site, than to fix it later when there are (hopefully, good luck anyway) thousands of users overloading your server

likely all this stuff can be found in one of the script repositories; hotscripts phpscripts cnet.download justscripts,
already made under general headings :: user-control, access control, subscription control, membership

edit

almostbob 866 Retired: passive income ROCKS

not marked solved
code sample

@media print { .dontprint {display:none;} }
<input type='submit' class='dontprint' value='send' />
almostbob 866 Retired: passive income ROCKS

No, the content of the iframe is generally stolen from an external site so has that site's scripts and css and copyright notice
contact the other site owner to request a copy of the content to include in your site with appropriate attribution,
or write your own content

all site owners should place framebreaker scripts in their menu include to prevent such theft

almostbob 866 Retired: passive income ROCKS

the image is already linked, it is wrapped in an <a><img /></a>, can make the tumb display the large image on mousover and foward to the html page as the href, may accomplish what this code seemse to do

almostbob 866 Retired: passive income ROCKS

further explanation

<td><a class="zoom" rel="gallery" title="An image entirely created using a shape and layer effects. &lt;br/&gt; &lt;a class='galLink' href='wolfGlow.html' onclick='$.fancybox.close();'&gt;Click Here For More Info&lt;/a&gt;" href="images/gallery/wolfGlow/finished.jpg"><img src="images/gallery/wolfGlow/finishedTb.jpg" alt="" /></a></td>

title="An image entirely created using a shape and layer effects. &lt;br/&gt; &lt;a class='galLink' href='wolfGlow.html' onclick='$.fancybox.close();'&gt;Click Here For More Info&lt;/a&gt;" cant contain html, text only, links alts etc already inside a link throw the parser into fits
this scrap &lt;/a&gt; closes this link <td><a before the final > of the <a> everything after that fails

title="An image entirely created using a shape and layer effects."

almostbob 866 Retired: passive income ROCKS

no html in title tags

almostbob 866 Retired: passive income ROCKS

just the format of the code to put in the cookie too leave off the www and make the cookie refer to .mysite. let me open up my notes, probably the next link is the php one

edit: yep, subdomain cookies at php.net http://php.net/manual/en/function.setcookie.php

domain
The domain that the cookie is available. To make the cookie available on all subdomains of example.com then you'd set it to '.example.com'. The . is not required but makes it compatible with more browsers. Setting it to www.example.com will make the cookie only available in the www subdomain. Refer to tail matching in the ยป spec for details

in 'parameters' at the top of the page

peter_budo commented: Compasation for previous mistake +14
almostbob 866 Retired: passive income ROCKS

subdomain persistence cookes: try: http://www.15seconds.com/issue/971108.htm

almostbob 866 Retired: passive income ROCKS

infomation that wasnt in the first post,
sub1.mysite.com and sub2.mysite.com have the same path from the server root so
try <form action='<?php echo $_SERVER['DOCUMENT_ROOT'];?>/login.php' method='post'> if sub1.mysite.com is directed to www.mysite.com/subfolder1/subfolder2 then relative links ..(up one) will work even if they lead above the root of the subdomain <form action='../../login.php' method='post'> (demo: up two) it may be enough to count the folders back to the www root

both methods work, the first one on a site where subdomains all point to folders one level below the wwww root(planned in advance), the second on a site where the original work was built (hashed together) over years and many generations of code, (and is still patched when problems occur instead of being rewritten properly(aarrrgh time there is never enuf))

almostbob 866 Retired: passive income ROCKS

<form action='/login.php' method='post'> relative link on your site work?

almostbob 866 Retired: passive income ROCKS

sorry papanyquit, this happens often, no personal attack intended padding:0; zero has no dimension, dimensions may throw compliant browsers off and render in quirks mode
1px <> 1em <> 1%
0px = 0em = 0% == 0

I havent looked at prior solutions, this post may not be relevant to the thread

almostbob 866 Retired: passive income ROCKS

style the buttons
you can do anything in css

input.print {background:src(bla bla bla)}
<input class='print'>

has the appropriate image, you dont really need the image you can style the button itself, images take size, extra http calls, time

Lusiphur commented: That's why you make the big bucks... oh wait, we don't get paid for this do we? :P +1
diafol commented: nice AB +6
almostbob 866 Retired: passive income ROCKS

Includes are the right way to go
the file is processed as a single file includes are not separate
if the validation authentication were the first lines in include.php they are processed first, no part of the page is output to the browser untill after that include
the exit will always take place before browser output as long as only php functions that do not output to screen are in those include files
your worries seem to be baseless
changing back to no-include files would be an extreme retrograde step and increase the number of edits to individual pages not decrease them

almostbob 866 Retired: passive income ROCKS

cant help you, but I can make it easier for those who know how to asnwer, to be able to help you, the screen shots are useless to anyone
post the code of the page, between
[code=html] put code here

[/code]
code tags so that one of the html mavens can sort out the issues, tables are very 1980s

almostbob 866 Retired: passive income ROCKS

the default for multiple addresses is separated by ; semicolon
try just editing the to: address address1;address2

almostbob 866 Retired: passive income ROCKS

what you are asking for is not what you are attempting
you asked for a form processed by a php form handler after it has been validated by a javascript ?
wrong way to do things
javascript validation isnt validation, it can be faked wrong blocked disabled
the form should submit to the form handler to be validated, basic javascript validation can be used, prior to submission, but its no value for real work
if validation fails, return to the form for correction

<form method='post' action='phpscripthandler'>
<input name='ralph' value='<?php if isset($_GET['ralph'] echo $_GET['ralph']; ?>'><label for='ralph'> ralph</label>
bla bla bla

example code ralph is populated with return values from the handler script to be edited for resubmission

almostbob 866 Retired: passive income ROCKS

something like

<form action='submit_me.php' method='post' onsubmit='validate_javascript();'>
bla bla bla
<input type='submit'></form>
almostbob 866 Retired: passive income ROCKS

that is an unneccessarily convoluted way to echo text, what do you actually want to achieve

almostbob 866 Retired: passive income ROCKS

there is no width set for the body, so you get the browser defaults
try

#footer{ width:100%; height:23px; background-image:url('../img/site_layout/footer_gradient.gif'); background-repeat:repeat-x; 	margin-top:40px; margin-bottom:-8px; text-align:center; }

try also to get away from pixels for layout
px dont work, on any monitor except yours the layout may be totally unviewable, users leave in droves if there are horizontal scroll bars, mice dont have hscroll wheels
and if they have a widescreen, most of the screen is unoccupied

px dont adjust to user preference
px become vanishingly small on hi res-monitors, annoyingly large on low res (like handheld) devices
current best practice is ems , % for anything except an image, images are pixel sized
using a relative scale, like an em or %, allows for accessibility,
blind freddy to set his basefont to 100px,
your site adjusts to a font that blind freddy can read, based around 100% or 1em being 100px
for blind freddy, 14px might as well be 1pxto any visually impaired person named Fred, blind freddy is an archetype not an individual

almostbob 866 Retired: passive income ROCKS

the time limit is 30 minutes on editing
the .ie version works
consider nailing the dotcom as well for future expansion or name recognition,

looking at the css

almostbob 866 Retired: passive income ROCKS

there is only a parking notice

at least 3/4 of the parking page is blocked as malware
and I'm not going to disable the block

post the html and css of the page, the source view is useless for a php page

almostbob 866 Retired: passive income ROCKS

In what form is the date stored, as a date object or in some text form, comparing DMY d - m y y-MD makes a lot of difference, it may be impoosible to match different date formats

edit, impoosible ?? ha ha

almostbob 866 Retired: passive income ROCKS

show your code, one of the gurus will be able to point you right

almostbob 866 Retired: passive income ROCKS

every array,

edit lost a bit there

every array starts as array[0]

almostbob 866 Retired: passive income ROCKS

show the code with which you place the background
is the background a tiny repeat-x, or a large image
otherwise shooting in the dark

almostbob 866 Retired: passive income ROCKS

There is good reason why you seldome see <base>, it seldom works
declaring relative links start at XXX is a total stuffup, is difficult to maintain, does not allow portability

almostbob 866 Retired: passive income ROCKS

you have to put the formatting in, something like

echo "'";
$str = file("sheet5.txt");
foreach($str as $line){ echo nl2br($line)."','"; }
almostbob 866 Retired: passive income ROCKS

the reply says it is not finished code,
it is a scrap of sql as a thought pattern, it would have to be properly setup in php mysql handling

the code that updates last_login login_count is_loggedin (and any other) should be in whichever file logs the user in, code for monitoring whether login is current has to be in EVERY page, so usually put it a menu include() file

almostbob 866 Retired: passive income ROCKS

the usual thing is a routine in the script that logs pages, keeps note of logged in users movements, that timesout other sessions if inactive for (preset time),

almostbob 866 Retired: passive income ROCKS

table columns, last_login login_number
add to your php login script

update members set last_login=now() where user=$user
update members set login_number=login_number+1 where user=$user

code sample only, not checked, (laptop in public wifi, no notes)

once the timestamp is set then you can use php sql datetime functions to find any users who havent/haved in within any timespan

Or
create another table for visits keyed to the userid

almostbob 866 Retired: passive income ROCKS

part of a very much larger .htaccess file, .htaccess==goldmine

AddHandler server-parsed .html
Options +Includes

<Files .htaccess>
order allow,deny
deny from all
</Files>

RewriteEngine On
RewriteCond %{HTTP_REFERER} !^$
RewriteCond %{HTTP_REFERER} !www.mysite.com [NC]
RewriteRule \.(jpe?g|gif|bmp|png|wmv|asf)$ /images/nohotlink.jpg [F,NC]

ErrorDocument 404 /notfound.php
ErrorDocument 401 /needpassword.php
ErrorDocument 500 /noserver.php

<IfModule mod_expires.c>
ExpiresActive On
ExpiresByType text/html "access plus 2 days" 
ExpiresByType image/gif "access plus 60 days"
ExpiresByType image/jpg "access plus 60 days"
ExpiresByType image/png "access plus 60 days" 
ExpiresByType application/x-javascript "access plus 60 days"
ExpiresByType text/css "access plus 60 days"
ExpiresByType image/x-icon "access plus 360 days"
</IfModule>

in order::
allows includes in html
stops outsiders reading .htaccess
blocks most image thieves
custom errormessage handlers
puts a default date on filetypes for spiders and browser cache

.htaccess server parsed files adds neglible time to serving the file, the file is only read once, not twice as previously noted, .htaccess acts on apache web server layers, well below the html is served

but why? not show shtml as shtml, or modernize it at least to php or asp, all users are accustomed to seeing filetypes other than html, no web site is static any more
for only 150 pages,
thousands of php pages from database on each site and is less server load (more importantly far less disk space) than the static pages were,
new information loaded by AJAX that may only require 25 bytes, not 25KB for a new static pageanyhow small kudos for trying to โ€ฆ

almostbob 866 Retired: passive income ROCKS

$fileNum does not need to be dquoted,
in double quotes the php parser will search text, for variables
all of these work

$path = "img$fileNum";
$path = "img".$fileNum;
$path = 'img'.$fileNum;

putting the variable inside quotes is slower (infinitessimally) than leaving it outside where it belongs, above line3 (single quoted text) is fastest, the php parser does not waste time looking for variables where none exist.
May not matter for 1 image, may matter for many images

almostbob 866 Retired: passive income ROCKS

having a better understanding of the problem,, still no solution, more thoughts that again may not be appropriate
Is it possible on the source/script generating the .csv file to have it create sequential files each consisting of a subset of records
eg, id 0-999; 1000-1999; ...... x000-x999
and process 10(example) smaller files to keep execution time below timeout for each iteration of the scriptupload.csv :: contains a single line to tell the script how many files there are in the data set so the script knows how to handle
upload0001.csv
upload0002.csv
upload0003.csvwould give a simple way to jump to a known record

almostbob 866 Retired: passive income ROCKS

why would you send 42000 lines if you want 1
the script that creates the csv file for upload, could it be smart enough to check for modified data,
then import all the lines of the much smaller file
I think I am suggesting a proceedural change to the data collection

database has a crc column
on update from remote, the list of id and crc are compared to local versions and only updated lines sent
may not be possible, thought process not any actual code

almostbob 866 Retired: passive income ROCKS

I have a solution,
offended, screw em

almostbob 866 Retired: passive income ROCKS

investigate the html <label> tag, will make your input forms more user friendly, by providing the stardard clickable-text that activates the radio button

<script type='text/javascript'>
function show(sec) {
document.getElementById('sec0').style.display='none';
document.getElementById('sec1').style.display='none';
document.getElementById('sec2').style.display='none';
document.getElementById('sec3').style.display='none';
document.getElementById(sec).style.display='block';
} </script>
Section:<br>
|<input type='radio' name='section' id='section1' value='section1' onclick="show('sec1');"><label for='section1'> Section 1</label>|
|<input type='radio' name='section' id='section2' value='section2' onclick="show('sec2');"><label for='section2'> Section 2</label>|
|<input type='radio' name='section' id='section3' value='section3' onclick="show('sec3');"><label for='section3'> Section 3</label>|
<div id='sec0'>| Reason |</div>
<div id='sec1' style='display:none;'>
|<input type='radio' name='reason' value='reason1' id='reason1'>
<label for='reason1'>reason 1</label>|
|<input type='radio' name='reason' value='reason2' id='reason2'>
<label for='reason2'>reason 2</label>|
|<input type='radio' name='reason' value='reason3' id='reason3'><label for='reason3'> reason 3</label>|
</div>
<div id='sec2' style='display:none;'>
|<input type='radio' name='reason' value='reason4' id='reason4'><label for='reason4'>reason 4</label>|
|<input type='radio' name='reason' value='reason5' id='reason5'><label for='reason5'>reason 5</label>|
</div>
<div id='sec3' style='display:none;'>
|<input type='radio' name='reason' value='reason6' id='reason6'><label for='reason6'>reason 6</label>|
|<input type='radio' name='reason' value='reason7' id='reason7'><label for='reason7'>reason 7</label>|
|<input type='radio' name='reason' value='reason999' id='reason999'><label for='reason999'>reason 999</label>|
</div>

all the radio buttons can have the same name, as only groups of them are shown
the IDs give the <label> tag something to anchor to

ShArKss commented: Solved the problem! Love this guy! +0
almostbob 866 Retired: passive income ROCKS

complete code required for one of the mavens to be able to point and fix, those three lines are not enough

almostbob 866 Retired: passive income ROCKS

that means the .js files on your server are not stored on your localhost development system, severely messes up if the two are not identical
If you have ftp access you should download all the server html css js files to the development system, images etc dont matter,
if you dont have the localhost complete, every alteration will have to be individually uploaded to the host to be tested
that is a pain, and total snafu can result
IF the localhost is complete development is a snap, you can make any changes you like without killing the server

javascript menus dont work where javascript is disabled for security (large %age getting larger everyday)
css menus work everywhere

almostbob 866 Retired: passive income ROCKS
<link rel='stylesheet' href='http://www.cpi.com/interior.css' type='text/css' media='screen'>

yes, not having the pages on the server location pointed by the base href will cause problems
you can comment out the base statement during development on the localhost, and re-enable it before uploading to the server, to make sure the rest of the links work

<!-- <base href='etc'> -->
<!-- commented out for development -->

hoping that the menu is a php/asp/shtml include so you only have to do any alterations once for all files

almostbob 866 Retired: passive income ROCKS

code ? to make sure, but,
<base> the href that relative urls start from, easiest fix is kill the base and set the proper url to the menu include

almostbob 866 Retired: passive income ROCKS
@media print { .dontprint { display:none; } }
@media screen { .dontshow { display:none; } }

then anything you wish not to print, at the 'dontprint' class to
eg

<span> inline </span>
<div class='header'>menu stuff</div>
<!-- becomes -->
<div class='header dontprint'>menu stuff</div>

I like dontprint, its a descriptive name
css @media types allow you to customize appearance for the output, so youcan ..

<div class='header dontprint'>menu stuff</div>
<div class='header dontshow'>alternate header for printed page Wow, cool</div>

:)
in css you can

@media screen { /* loads of css to define appearance */ }
@media print { /* loads of different css to redefine appearance on papaer */ }

On screen I have a logo that floats at the bottom corner of the screen and includes a goto top link,
on paper a logo that is fixed at the corner of the page and includes copyright and printed contactus

almostbob 866 Retired: passive income ROCKS

CloudNine,
Errors & error messages (if any) will depend on changes to server php versions, and will come when/if your host updates the version of php on the server, always without advising anybody before making the change.
If you are aware of the possibility of error, and the likely cause(s), when/if the error occurs, the solution is already known, and you can remove that semicolon, or switch to heredoc syntax
file it, under JustInCase

incidentally some code is much messier than that
time constraints to 'get it working' and make it prettier later
later always comes much later (never) after someone paying the bills has asked for yet another urgent change
form follows function, or a good landing is any you can walk away from

dos v'danye

almostbob 866 Retired: passive income ROCKS

the background image occupies the window and text slides over it as if written on a glass sheet,
the user sees no difference to a stretched image, the background is always in place, except the image is not distorted and stretched to fit a 2500px(example) high page

look at this demonstration and see if it changes your mind

almostbob 866 Retired: passive income ROCKS

why not
fix the background in place and have the content scroll over it

body {background:#ffffff url('img.png') no-repeat fixed 0 0;}
almostbob 866 Retired: passive income ROCKS

show ALLthe code

almostbob 866 Retired: passive income ROCKS

thanks for reminding me about onblur. that was just added stuff its not incorrct anyways. this is a javascript forum. if u want css, which u have no reason to post all that code really if u just want a transparent background for a few input boxes.. then its done like this(this is a javascript forum tho.. ok)

input.tags{width:255px;background:transparent}
<input class="tags">

without casting any rocks,
the forum is javascript, does not make the solution best done in javascript
lots of questions get asked, and answers given, that would be better asked in another forum,
SQL in php,
presentation in javascript

there is always another way, sometimes a better way, always a better way than inline anything for every tag,
maintenance becomes horrible

almostbob 866 Retired: passive income ROCKS

jvascript should not be used for this purpose
javascript is disabled as a security risk on a large %age of browsers
the code scrap supplied is incorrect,
it handles onfocus, but does not handle onblur