architact 25 Junior Poster

Hello I am trying to develop a group site where a user can signup and create group and other user can signup and join the groups created by other users, each user will have a wall where the posts from the groups they joined will appear, I need help in trying to understand how can I implement it using php / mysql, how can I link a post from a group to a user, any help will be appreciated.

Thanks

architact 25 Junior Poster

Hello, I just finished creating an online site builder and now its time to launch it, I am facing a problem related to URL-Rewriting.

My site builder contains all the files and folders which will make up the client's site inside a folder named as "usersite", and can be access theough http://www.mydomain.com/usersite, what I want is that instead of "usersite", I want to display the user's choosen username in the address, I have tried many way but nothing is working, Right now what I have is that I have to create a rewrite rule for each registered user manually.
E.g

Options +FollowSymlinks
RewriteEngine On 
RewriteRule ^user1/(.*)$ usersite/$1&teamname=$0 [nc]
RewriteRule ^user2/(.*)$ usersite/$1&teamname=$0 [nc]
RewriteRule ^user3/(.*)$ usersite/$1?teamname=$0 [nc]
RewriteRule ^user4/(.*)$ usersite/$1?teamname=$0 [nc]

This code is not working completely as if I access a page with query string in the address I can't access the query string variables.

Please help me with this problem.

Thanks in Advance.

architact 25 Junior Poster

Hello, I am developing a site and right now I am facing a problem when I try to upload the code on the server, everything is fine and working there except the flash files, the ".swf" files are showing on the page when access them through the website but they are not loading flv files, and when i try to access the flv files I receive 404 error, please tell me what should I do, I think this is problem due to permissions but I am not aware of how to change them, I am using a windows server.

Thanks

architact 25 Junior Poster

First .htaccess file:

RewriteEngine On
RewriteRule ^\.htaccess$ - [F]
RewriteCond %{HTTP_HOST} ^([^.]+)\.domainname\.com$
RewriteRule ^$ /index.php?user=%1 [L]

Second, we must set a redirection from whatever "username.domainname.com" link to "domainname.com". Thats achieved by talking to your hosting provider to setup such a redirect.

Third, according to your site link generation, modify the last line in .htaccess provided lately. In my case it was "index.php?user=1", which was transformed to 1.domainname.com.

Thank You AMD_K8, I will give it a try.

architact 25 Junior Poster

Hello, I am developing a site on which upon registration the users will receive a personal site with the address

username.domainname.com

Please tell me how this can be achieved, I think it might b possible with the use of mod_rewrite but I am not sure.

Please help me with this problem.

Thank You

architact 25 Junior Poster

Hello, I am assigned with the task of cloning digg.com, I am doing quite well except one issue, I want the user to enter a link in a text field and then I want the take a screen shot of that url (like digg.com). Please help me with what libraries should I use.

Thanks

architact 25 Junior Poster

Hello, I want the ability for my clients to authorize the payment at the signup and pay when they will confirm their account. I have Googled about it and found the Paypal Authorize and Capture for this purpose.
I was unable to found tutorial for A&C.

Please tell me if there is a better solution or where can I find the tutorial for the authorize and Capture.

Thanks

architact 25 Junior Poster

Ok, I guess by using the Hidden field with the name "amount", am I right?

architact 25 Junior Poster

Hello, I have created a site where users will have to pay fee for signup, that fee will be calculated using the options the select. I want them to be able to pay their fee using Paypal, I know how to process a fixed amount using paypal but don't know how to process variable amount using paypal. :sad:

Please help me with it.

Thank You.

architact 25 Junior Poster

Thanks alot for your help, But Then how can I use it over the net. Because each user will not have that image in directory,

architact 25 Junior Poster

Your problem is just as the exception describes, the file doesn't exist. Try giving an absolute path to the image.

It means that I should give a path like this http://www.site.com/img.jpg
??

architact 25 Junior Poster

Hello Coders, I am trying to generate the pdf file using php, I successfully generated the php file and then I tried to insert an image in the pdf file using php and got this error, I have the image and file in the same directory and don't know why the code is failing please help me.

Error:
Fatal error: Uncaught exception 'PDFlibException' with message 'Couldn't open JPEG file 'test.jpg' for reading (file not found)' in C:\xampplite\htdocs\score\scorepass\pdfgeneration.php:13 Stack trace: #0 C:\xampplite\htdocs\score\scorepass\pdfgeneration.php(13): pdf_open_image_file(Resource id #5, 'jpeg', 'test.jpg', '', 0) #1 {main} thrown in C:\xampplite\htdocs\score\scorepass\pdfgeneration.php on line 13

<?php
$pdf = pdf_new();
pdf_open_file($pdf,"c:\scorefm.pdf");
pdf_set_info($pdf, "Author", "Author");
pdf_set_info($pdf, "Title", "Title");
pdf_set_info($pdf, "Creator", "Author");
pdf_set_info($pdf, "Subject", "Coupoun");
pdf_begin_page($pdf, 504, 264);	
$image = pdf_open_image_file($pdf, "jpeg", "test.jpg", "", 0);
pdf_place_image($pdf, $image, 504, 504, 1); 
$font = pdf_load_font($pdf, "Courier","iso8859-1", "");
pdf_setfont($pdf, $font, 10);
pdf_end_page($pdf);
pdf_close($pdf);
?>

Please Please help me.

architact 25 Junior Poster

php/mysql

architact 25 Junior Poster

Hello Guys I want to connect two databases at the same time but it looks like the php is only picking up the second database.

One database is on my localhost and the other one is on server, I want to transfer the data from my localhost database to the database on the server. I have also tried passing the 4th argument to the mysql_connect function but I can't get it to work.
mysql_connect("localhost", "name", "password", true);

Please help me.

Thanks

architact 25 Junior Poster

Hello Everyone,

I have a pretty simple problem for an expert. I want to access the database on the server from my localhost, I don't know how to do it. On our localhost the way is mysql_connect("localhost","name","password");
But how I will access the database on a server from my localhost??
Please help me.

architact 25 Junior Poster

Thanks to all of you the problem was solved after robothy's reply but almostbob thanks to you as well.

architact 25 Junior Poster

Hello Guys, I need a simple help in css (I think so). Please have a look at this page http://www.csszengarden.com/?cssfile=213/213.css You will find some images at the bottom of the page that remains there whether you scroll up or down, I want to know how can achieve this. I think it is a property of css. Correct me?

architact 25 Junior Poster

Hello, I am wondering how can I install and use geolocation api by Google so that I can use it in my website. I have spent 2 hours for this searching on google, yahoo, mamma, ask but not found a solution so please help because I am ready to throw my computer out of the window with myself to follow.

Thanks

architact 25 Junior Poster

PHP

architact 25 Junior Poster

Hello, I am developing a website but I am stuck at a point.

I have a table having Sundays, video, and photo1, photo2, photo3 as columns.

I have a form on a web page having three check boxes "with videos", "with photos" and "Open on Sundays", I want to get results based on these controls please help me. If open on Sundays is checked then the query will return the results where Sundays have value "yes", if "with photo" is checked the query will return where photo1 or photo2 or photo3 is not empty.

architact 25 Junior Poster

Hello, I am trying to develop a calender using the flash's built-in date chooser component, what I want to do is that I want to pass an array of dates to flash from javascript and then disable that dates in the calender component, Please help me in doing this.

Thanks

architact 25 Junior Poster

on original site it is used in this way.
mysql> SELECT DAYNAME('2000-01-01');

how can i store the resuilt of DAYNAME in a variable.

architact 25 Junior Poster

<?php
mysql_connect("localhost", 'root', '12345678');
$d = mysql_query("SELECT DAYNAME('2000-01-09')")or die(mysql_error());
echo $d;
?>

architact 25 Junior Poster

Hello, How can I find out the day of week, using given date using php or mysql, I have searched for it on google and find out a mysql function DAYNAME but when I used this function the output is "Resource id#3" please help me in solving this.

Thanks

architact 25 Junior Poster

Thanks guys but problem is I want to do this for a form having 77 fields. Isn't there a simple method.

architact 25 Junior Poster

Hello, I am developing a website for which I am designing a signup form, the problem is a user fills the form and miss a field when they go back to enter that field it cleans up all the remainig field and they have to fill the whole form again. Please help me how can I achieve this.

architact 25 Junior Poster

Hello Guys please tell me what are the differences between Object Oriented and Structured Programming. Thanks.

architact 25 Junior Poster

Hello, Please tell me the way how can I turn on error reporting/php warnings in apache2triad.

architact 25 Junior Poster

Hello Langsor, thanks for your reply but I don't want to read rss feed, I want to create a rss feed.

architact 25 Junior Poster

Hello, Please help me in understanding the mystery behind rss feed, how to create it?, is it an automatic process? or it requires some admin type thing?

Please help me, I want to know how to create a rss for a website.

Thanks.

architact 25 Junior Poster

it is wrong $_POST is correct and instead of [1] use foreach loop.

architact 25 Junior Poster

Hello Everyone,
The problem I am facing is very simple, I want to add daily news letter subscription for the users on a site. Please tell me how can I do that.

Thanks

architact 25 Junior Poster

yes. Session will not end immediately after the browser is closed, it takes almost 3-4 minutes.

architact 25 Junior Poster

why don't you use cookies

architact 25 Junior Poster

weired its working on my pc, try the attaced files

architact 25 Junior Poster

Check this one

<?php
include 'Images_db_connect.php';
mysql_connect("$host", "$username", "$password")or die("cannot connect"); 
mysql_select_db("$db_name")or die("cannot select DB");
//define a maxim size for the uploaded images in Kb
 define ("MAX_SIZE","75"); 
if(isset($_FILES['file']['name']) && $_FILES['file']['name']<>""){
$typ = $_FILES['file']['type'];
if($typ == "image/gif" || $typ == "image/png" || $typ == "image/jpeg" || $typ == "image/pgif" || $typ == "image/ppng" || $typ == "image/pjpeg"){
$uploaddir = "images/";
$uploadimages = $uploaddir.$_FILES['file']['name'];
if(move_uploaded_file($_FILES['file']['tmp_name'], $uploadimages)){
$imagename = 'image name';
$caption = 'caption';
$category = 'category_name';

$sql = "INSERT into photos (image_name, caption, image_path, category) VALUES ('$imagename', '$caption', '$uploadimages', '$category')";
mysql_query($sql) or die(mysql_error());

echo "File successfully copied";
}
else{
echo "Copy unsuccessful";
}
}
else{ 
echo "Incorrect file type";
}
}
else{
echo "No file selected";
}
?>
architact 25 Junior Poster

love

President Bush is the greatest________________.

architact 25 Junior Poster

And also to find Wi-Fi Spot.

architact 25 Junior Poster

To reach internet so they can login to daniweb.

architact 25 Junior Poster

I was dying.

architact 25 Junior Poster

Hurry up complete these sentences with Yes or No:

  1. _____________, I am not a honest person
  2. _____________, I will cheat you.
  3. _____________, I am an idiot.
architact 25 Junior Poster

PEN

Xbox 360 or Playstation 3 or GameBoy

architact 25 Junior Poster

She is not dancing on my browser, BRAVO

architact 25 Junior Poster

I am gonna hack google. (dream of a child) :cool:

architact 25 Junior Poster

this is probably the worst thread ever.

Daniweb has really lost quality in the last couple years.

Hey you know the meaning of SHIT.??? :D

~s.o.s~ is right please spend sometime on http://www.mammasmilk.com/

~s.o.s~ commented: Haha, nice link. :-) +23
architact 25 Junior Poster

Can you explain more...

architact 25 Junior Poster

Thanks a lot langsor, the solution i figured out is that hide the button while the layer is animating.

architact 25 Junior Poster

it can be relative, please try a gif or png file and then tell me the result.

architact 25 Junior Poster

Check the folder where image is to be copied, the script is copying the file or not??

architact 25 Junior Poster

Hello, I want to use javascript to fade in a layer after the user click a button. please help me I want to that animation to work in Internet Explorer and Firefox, I searched on google and found. obj.filters.alpha.opacity, but it doesn't seem to work.

Please Help Me.