Tracking Forums, Newsgroups, Maling Lists
Home Scripts Tutorials Tracker Forums
  Advanced Search
  HOME    TRACKER    PHP


Advertisements:




SuperbHosting.net & Arvixe.com have generously sponsored dedicated servers and web hosting to ensure a reliable and scalable dedicated hosting solution for BigResource.com.







Wildcard Cookie


what would make IE not take wildcard cookies. works in forefox however. domain: .example.com PHP:

session_set_cookie_params ( 60*60*24*2, '/', '.example.com', false);


View 1 Replies (Posted: 8:28 pm on April 12, 2007)

Sponsored Links:

Related Forum Messages:
Wildcard Help?
I'm trying to do the following and it's not working.

if ($compare_product == '***%'){
echo ("<p class="footnote">***UDL packages trade name product</p>
");
}

So basically i'm saying that if $compare_product begins with *** then print the message.

Posted: September 13th, 2001, 10:27 AM

View 3 Replies!   View Related
Wildcard With Php Self
i have scripts and pages that only respond in certain "Cities" on my site... by doing this is put the first letter of each city infront of the script names so there are all like Lhome.php Lgym.php etc Now what i want to try and do is something where by using $_SERVER['PHP_SELF']

I want to use a wild card to do if $_SERVER['PHP_SELF'] begins with L wildcard then ok, else header location "phpscript.php"

Posted: October 28, 2007, 12:29:03 PM

View 9 Replies!   View Related
Wildcard?
I have a script which receives _POST data from a program. I need to make sure that any data that has 747 in it, will be given a value I determine.

I was thinking about something along these lines:

$aircraft = $_POST[aircraft];

if ($aircraft == "%747%") {

$aircraft = "B747";}

Would that work? I was thinking along the lines of the mySql LIKE commands where a % would be a wildcard. In other words, I want to check the variable $aircraft and if this variable has any reference to "747" (ej. Boeing747 or B747-200, et etc), then it will simply make it "B747".

Posted: October 11, 2007, 07:41:04 PM

View 7 Replies!   View Related
My Wildcard
I'm working on making my MySQL and PHP web database searchable. I'm testing on searching on a field called strAddress, which holds the street address. The sample population of the street addresses is:

1 Caroline Street
13 Caroline Street
Caroline Street

On the calling page this anchor tag successfully finds the one record with the "Carloine Street". I want to use two wildcards in the anchor tag to find all of the above 3 addresses. This does not work, it returns no records. What's wrong? Can I not start the variable assignment in the link with a wildcard?

Posted: 09-02-2006, 03:55 PM

View 1 Replies!   View Related
Wildcard DNS
It's a shorter URL site. But you can name the links instead of just getting a random string (you have that option as well). Does this seem like something people would use?

Posted: July 17th, 2005 10:29 AM

View 15 Replies!   View Related
Using Wildcard
I am attempting to setup an array and want to use a wild card. I have different catagories with multiple pages in each catagory.

The pages in each catagory will have the same titles and same metatags, but the titles and metatags will be different in different catagories. I know Im rambling thisd is what I want to do will it work or is there an easier way. Code:

Posted: 6:19 pm on Feb. 16, 2005

View 1 Replies!   View Related
Wildcard
I want to show the last digit of a members ID like:

ID 46 = 6

I thought i could use % to define the first number, but i only get error messages...

Anyone who knows what I should do?

Posted: 06-15-2005, 03:05 PM

View 2 Replies!   View Related
Wildcard Question
"Recent Visits" list, I try to exclude all *.googlebot.com and the
like.
Now, I tried the following:

if (($HOST != "*.blah.com")
AND ($HOST != "*.googlebot.com")
AND ($HOST != "*.inktomisearch.com"))
{
// log this host
}

Nevertheless, it doesn't work.
How would I use the wildcard? I did not find any documentation on
wildcards.

--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet?

Posted: July 17th, 2005 02:43 AM

View 4 Replies!   View Related
Check Wildcard URL
I'm looking for a function that will help me determine whether or not a URL entered by a user matches specific requirements. This is done using $_POST.

Basically the format of the URL must be either: www.example.com, *.example.com, www.example.*, or *.example.* - or some kind of combination such as www.url.com*. I don't want to allow a star in the 'url'. So in theory, to check this, all i would have to do is make sure the string contains: [www and/or *].[text].[text and/or *]

Posted: July 04, 2007, 10:46:19 PM

View 3 Replies!   View Related
Why Is This Acting As A Wildcard?
The input value is $Street = "Regent Street"

the validation check im using is:

QuoteElseIF($Street = " "){
die('You must select a street at the estate agents first!');}
Now in the IF check i have " " not "". I have done the check for "" but because i had a list box and one was blank with a " " option i had to put the check for it also. But for some reason im assuming the else if is finding the space between the 2 words and so the result becomes:

You must select a street at the estate agents first!

So is my if statement acting as a wild card to find the space " "? Cos im lost on why its showing the die.

Posted: August 28, 2007, 02:11:11 PM

View 2 Replies!   View Related
Str_replace With Wildcard
Any ideas to use a wildcard for numbers between brackets, 4-5 digits in length ??

example:
.sflor/12345/

my attempts - non-working

$page = str_replace (".sflor/??WILDCARD??/", "", $page);
$page = str_replace (".sflor/./", "", $page);
$page = str_replace (".sflor/[0-9]/", "", $page);

ideas welcomed.

Posted: 02-08-2007, 10:55 PM

View 1 Replies!   View Related
Preg_replace Wildcard
"<div id="album0">No image found." until "</div>" and replace it with nothing so that its empty in that part. im not sure if i should be using preg_replace for this type of usage but i dont know anything else, if you could help out a bit it would be nice

Another problem, is that inbetween the "<div id="album0">" and "</div>" there are also another set of div tags, starting and ending tags.

Posted: 11-23-2005, 10:20 PM

View 1 Replies!   View Related
Wildcard Link
Instead of this:

echo "<a href="../ccdsv/images/$inv_no.jpg">";
echo "<img src="../ccdsv/images/thumbs/tn_$inv_no.jpg">";

Something like this

echo "<a href="../ccdsv/images/$inv_no*.jpg">";
echo "<img src="../ccdsv/images/thumbs/tn_$inv_no*.jpg">";

Posted: 06-07-2007, 01:42 PM

View 3 Replies!   View Related
Wildcard Search
Could someone tell me whats wrong with the following wildcard query please

$query="SELECT * FROM table WHERE $field = '$accno .% ' ";

Posted: 01-29-2006, 02:50 PM

View 2 Replies!   View Related
Wildcard Replace
I have around 45 or more paragraphs that goes like this:

1. START... bla bla bla ...END
2. START... bla bla bla ...END
3. START... bla bla bla ...END

Now I want php to search and replace the "bla bla bla" portion to "-hidden text-".
For example,

I want to search all "START*END"
and replace with "START -hidden text- END"
for all paragraphs.

The thing is I want to search with a wildcard and replace the text.
Is it possible? Can someone please help me with this?

Posted: 01-10-2006, 09:29 AM

View 2 Replies!   View Related
Wildcard With A Variable?
$query = "SELECT * FROM words WHERE word='$l%'";

This is for a dictionary thing that I'm making. All the spelling in there is correct, but it doesnt return anything.(there is one word in the dictionary and it is "word" and when ?l=w it returns nothing) I was wondering if this is a mysql problem or does it not like to have a % next to a variable?

Posted: 03-20-2006, 03:29 AM

View 4 Replies!   View Related
Wildcard DNS With URI Request?
I want to redirect name.domain.com/trips/1 to domain.com?username=name&trip=1 using modrewrite. Is this possible? I have the dns set up correctly however - I am unsure about the htaccess file. Can I link all this information to one PHP or do I need to create a directory for every user?

Posted: Mar 16 10 at 11:50

View 2 Replies!   View Related
Basic Script To Test A Cookie - Browser And The Cookie Wont Show Up On The Page?
I have a basic script to test a cookie.

Login.php
<?php
include('connect.php');
$username = $_POST['username'];[code].....

Error:

Undefined index: user in C:\wamp\www\scripts\menu.php on line 14

I looked in my browser and the cookie is there with the right name but it wont show up on the page.

Posted:  Posted 17 September 2009 - 02:25 PM

View 9 Replies!   View Related
Passing MySQL Wildcard Into URL
I have a search feature where users can search a database. All works
very well except for one small annoying bug.

If a user searches for anything using wildcards and the '%' is the
FIRST character searched for, my pagination routine doesn't pass the
correct value.

Say the user enters %300. The page displays the correct data for the
first page, indicates that it is page 1 of 11 and when the NEXT link is
clicked, the value changes to 00. I haven't figured out why the %3
drops, however I suspect it may be my use of quotes. Particular code is
below. Can anyone help me?

Platform is Apache on FC3, MySQL and PHP. Browser being used doesn't
matter.

<?
if($pageno == 1) {
echo "<TD CLASS=upperLinks>FIRST&nbsp;</TD><TD
CLASS=upperLinks>PREV&nbsp;</TD>";
echo "<TD CLASS=data1>FIRST&nbsp;</TD><TD CLASS=data1>PREV&nbsp;</TD>";
} else {
echo "<TD CLASS=data1> <A
HREF='{$_SERVER['PHP_SELF']}?pageno=1&searchfor=$searchfor&searchtype=$searchtype'
CLASS=upperLinks>FIRST</A></TD>";
$prevpage = $pageno - 1;
echo "<TD CLASS=data1> <A
HREF='{$_SERVER['PHP_SELF']}?pageno=$prevpage&searchfor=$searchfor&searchtype=$searchtype'
CLASS=upperLinks>PREV</A></TD>";
}
?>
<TD CLASS=data1>(Page <?=$pageno?> of <?=$lastpage?>)&nbsp;</TD>
<?
if ($pageno == $lastpage) {
echo "<TD CLASS=data1>NEXT&nbsp;</TD><TD CLASS=data1>LAST&nbsp;</TD>";
} else {
$nextpage = $pageno + 1;
echo "<TD CLASS=data1> <A
HREF='{$_SERVER['PHP_SELF']}?pageno=$nextpage&searchfor=$searchfor&searchtype=$searchtype'
CLASS=upperLinks>NEXT</A></TD>";
echo "<TD CLASS=data1> <A
HREF='{$_SERVER['PHP_SELF']}?pageno=$lastpage&searchfor=$searchfor&searchtype=$searchtype'
CLASS=upperLinks>LAST</A></TD>";

Posted: July 17th, 2005 12:46 PM

View 5 Replies!   View Related
Wildcard On File Exists
Is it possible to run something like:

if(file_exists("dir/h*.jpg")) { something } else { something else }

Posted: 8:23 pm on Sep. 4, 2007

View 1 Replies!   View Related
Can I Pass A Wildcard To This Function?
Is it possible, accidentally or on purpose, to pass a
wildcard to this function that would have the effect
of deleting many or all rows (shortname is a unique,
non-null field)?

function delete_row_by_shortname($table,$shortname){
global $mysqlhost, $mysqlusr, $mysqlpw, $mysqldb;
$link = mysql_connect($mysqlhost, $mysqlusr, $mysqlpw);
if (!$link) {
die('Not connected : ' . mysql_error());
}
mysql_select_db($mysqldb) or
die ('Could not select database:' . "$mysqldb.");
$query = "DELETE FROM $table WHERE shortname='$shortname'";
mysql_query($query) or die ("Query Failed! mysql_error()");
$value = mysql_affected_rows($link);
mysql_close($link);
return $value;
}

Posted: June 14th, 2007 07:25 AM

View 3 Replies!   View Related
If Statement With Wildcard Characters?
What I have is hundreds of names, such as   this-1 this-2 this-3.

The if statement I have so far is   if($blah == "this-")

How can I make it so that the if statement will be true if $blah at least matches 'this-' ?

Posted: August 15, 2007, 04:00:40 PM

View 3 Replies!   View Related
Wildcard For String Replace
In the following code I need to replace SOMENAME with a wildcard. SOMENAME changes on a regular basis so I have no constant. Code:

Posted: June 02, 2007, 11:19:57 PM

View 6 Replies!   View Related
Wildcard Search On Array
I have this search-thingie that searches through a text file for occurences of user input string (from a form). Everything works fine untill user wants to do a wildcard search. I'm not sure if that is the right term for that, but I am talking about searches with * and ? in it. Is there a way to do these kind of searches from an array? Any help is welcome.

Posted: 12-14-2005, 10:12 PM

View 1 Replies!   View Related
Wildcard Search Problem
I have a search field that is numeric and can contain up to 4 digits. When I query using LIKE I'm getting all numbers that contain the queried integer. How can I constrain to just the desired number? var2 is the number Code:

$var1_Recordset2 = addslashes($_GET['name']);
$var2_Recordset2 = addslashes($_GET['class']);

mysql_select_db($database_mt_connect, $mt_connect);
$query_Recordset2 = ("SELECT * FROM mt_students WHERE sname like '%".$var1_Recordset2."%' and class like '%".$var2_Recordset2."%'");
$query_limit_Recordset2 = sprintf("%s LIMIT %d, %d", $query_Recordset2, $startRow_Recordset2, $maxRows_Recordset2);
$Recordset2 = mysql_query($query_limit_Recordset2, $mt_connect) or die(mysql_error());
$row_Recordset2 = mysql_fetch_assoc($Recordset2);

Posted: 11-10-2006, 02:09 PM

View 3 Replies!   View Related
Wildcard A Href Id With Jquery?
I have a series of links as so:[URL]

Is it possible with jquery to have it execute a function if anything with an id of linkXX is clicked and then shuttle you over to the link target? The links themselves will be variable in number, target and id name, the only unifying feature is that the id will always have the words 'link' followed by 2 numbers.

Posted: Jul 3 at 13:41

View 3 Replies!   View Related
Mysql Query Against Wildcard?
I have a mysql query in php, using match / against to filter results. Im trying to get a wildcard after $string so the next character can be anything. "SELECT * FROM $table WHERE MATCH (message) AGAINST('$string%' IN BOOLEAN MODE)"

Posted: Feb 23 10 at 0:19

View 2 Replies!   View Related
Using A Wildcard In Script Unlink?
I am currently making a php script to graph a bunch of data from a DB, arrange it into text files and then run a GNUPlot script to generate graphs. I have all of this working , now all I need to do is delete the text files I don't need anymore.

What I have been trying was gotten from another thread on a different forum:

foreach( glob('US_A.2.6.*') as $file )
{
unlink($file);
}

The problem, however, is that it doesn't work. The files have complex end names:

US_A.2.6.1.1a.txt
US_A.2.6.1.2a.txt
US_A.2.6.1.3a.txt
US_A.2.6.1.4a.txt
US_A.2.6.1.5a.txt
US_A.2.6.1.6a.txt

Posted: Jun 24 at 18:08

View 1 Replies!   View Related
Use A Wildcard As A Directory Level ?
What is the best way to skip over a directory level in PHP using some kind of wildcard expression?I have a config.php file that is unique to each child directory and I need to include it in the header of my page. What I want is to tell my main PHP page to include config.php when the name of it's parent directory may change?

Something like <?php include("http:[url]......

Posted: Apr 17 at 0:43

View 2 Replies!   View Related
File_exists With Wildcard For Extension?
file_exists with wildcard for extension. Is it possible to do a file_exists without an extension?I ask because I have about 750,000 if not more images, all of which follow a specific file_name format, that matches a key in a database I am working with. however, not all the formats are the same, I have gif, jpg, png, and I think maybe even a couple random .bmp. So I am trying to figure out if its possible to do anything like file_exists but without the extension, so that if it finds the file without the extension it will append the file type to the end of it so I can then call it out in html with img src...Anyone know if its possible? Can I use file_exists for something like this or am I thinking to much in the box with this, and need to broden my perspective of how I should build a function like this.

Posted: January 08, 2010, 02:31:00 AM

View 6 Replies!   View Related
Regex Preg_replace Not Getting Wildcard
I'm scraping a page and trying to remove the first part of the urls in a string of urls in the code. It needs to match a wildcard subdomain and a subfolder that has dashes in it. Here's what I've ended up with:

[Code]...

Note the forum won't let me post urls, which this is an example code, not an actual link, so replace the (put http here) with "http"

[Code]......

As you can see, it's pulling "domain" out of the subdomain instead of capturing the entire "subdomain". It's also not catching the entire subfolder after "item". ("item" is actually the first subfolder name so I can keep that in there) It's also removing the "and" which I want to keep since that's not part of the url.

Posted: April 20th, 2009, 07:46 AM

View 3 Replies!   View Related
Set Wildcard In $_SERVER['REMOTE_ADDR'] ?
is it possible to set $_SERVER['REMOTE_ADDR'] to a wildcard, so that anyone on the network can see this?

<?php
if($_SERVER['REMOTE_ADDR'] == "112.200.150.212"){
?>
<a href="http://www.tinycounter.com" target="_blank" title="free hit counter"><img border="0" alt="free hit counter" src="http://mycounter.tinycounter.com/index.php?user=fortressgate"></a>
<?php
}?>

but i want the network can see the counter... so it would look like this?

if($_SERVER['REMOTE_ADDR'] == "112.200.150.%")

Posted: Nov 30 10 at 1:34

View 2 Replies!   View Related
Apache Wildcard Setup ?
I have apache setup to wildcard direct all unknown trafic to one php script (default documentroot). This php script looks into a database and possibly finds the correct documentroot for the requested domain (or documetroot of the 404 error handler etc..). The problem is, that from within php script I know how to include another script, but can not change the documentroot - ie. force apache to set the found documentroot for the request, read htaccess file, run scripts etc.. can I? Any other solution? Must be allready somehow solved and solution is probably not very difficult, but was not able to create a fully working setup so far.

Posted: Feb 11 10 at 17:10

View 2 Replies!   View Related
Wildcard Sub Domain Path ?
I have an htaccess rewrite for wildcard sub domains which rewrites

[code]....

Posted: Jan 24 at 18:31

View 2 Replies!   View Related
Direct To Wildcard Subdomain?
a small script which will direct a person to wildcard subdomain.There should be an input field, a kind of <input name="letters" type="text" /> and it should direct a person to "letters" wildcard subdomain. What the users write in the input field, it should be a subdomain name, eg. a user writes abc in the input field and then is directed to a Is it possible to build such a script?I was looking for a solution for several hours, in vain still... I don't know much php, so if you can

Posted: 06-30-2009, 12:12 PM

View 1 Replies!   View Related
Cookie Stored On Computer And Cookie Code In MySQL Database Does Not Match
I cannot work out why the cookie on my computer does not match the cookie id stored in the MySQL database.

I have this function creating a cookie

[Code].....

This mysql query does not work. The problem is the "cart.cookieId='" .GetCartId() ."'". Without this it is fine. With it, it does not work.

As you can see above the cookieId is defined by the GetCartId function. As far as I can tell it must match but with this bit of code it does not work.

Posted: Jun 6, 2011, 01:53

View 2 Replies!   View Related
How To Write A Cookie To The Users Computer And Then Check To See If That Cookie Excists Before?
I've used sessions quite a bit, but I have never used cookies that are on the users computer.

In this project I am working on I need to have the user enter username and password and then if it's correct set a cookie on their computer that allows them to open new browser windows without having to re- enter the password. This isn't possible with sessions because when the browser is closed then the session ends.

Bascially, I just need to know how to write a cookie to the users computer and then check to see if that cookie excists before allowing access to certain pages.

Posted: 06-08-2005, 02:39 PM

View 2 Replies!   View Related
Wildcard - Delete A Row Once The First Variable Is Found
What can I use for a wildcard? I want to delete a row once the first variable is found like Name1. the problem is that the second part is encrypted. Is there a way to input the second variable so it matches the encrypted?

Name1:Mec3E.7GIcb9k
Name2:X9..uhgfderJuL

What can I use in this field that will pass any/or all that is listed. Code:

Posted: July 3rd, 2001, 04:21 PM

View 1 Replies!   View Related
Problems With Wildcard Characters Using Mysql_query() In PHP
We are using addslashes() before inserting data into mysql. Now, we face some problems while searching(selecting) particular data which contains slashes(as a result of addslashes..) by using LIKE statement. To compare such data we need to apply addslashes several times to our query data and it creates lot of problems to the further operations..

Posted: 08-13-2006, 10:21 AM

View 2 Replies!   View Related
Copyright © 2005-08 www.BigResource.com, All rights reserved