Jump to content

Ninjakreborn

Members
  • Posts

    3,922
  • Joined

  • Last visited

Everything posted by Ninjakreborn

  1. What are the purpose of classes, I have never used them. I always never had a need for them, is there a particular reason why they exist, what are they good for.
  2. Perfect I really appreciate it, I will keep this in mind, and use it, if I have something small I will create it. Thanks again that is what I was wondering.
  3. I am far from new at javascript, I have been working with it for 4 years on and off, but I have never stepped out of the lines of doing form validation, and small stuff like that, now I want to start creating full java script programs in my spare time, and either selling them, or renting them out, or keeping them for fun. I understand all the basic and intermediate concepts of javascript, and actually tried writing a few programs but didn't out of lack of inspiration. I had a few question about some things I wasn't sure of as pertaining to javascript. 1. Which is a better method Try Catch, or On Error. 2. Should I start utilizing try catch on all my scripts, if so how do I utilize it with if, else, and other like constructs. 3. What is the purpose of classes and what can they be used for, I have never used them, but I know the general format of setting them up and using, but don't see the point. 4. I want to create some javascript programs, where do I turn for inspiration, any ideas on possible programs, you get credit for the inspirational idea. 5. I have never had to use break so far, is it to get better timing during script execution. If so what do I need it for. 6. I also had one more question, say for instance I created a time and date function, and wanted to link them to something that states times and dates are based on your browser settings do I do it like this or another way. All math functions all date functions var mydate = date functions mytime = time functions you get the hint just showing you document.write('<a href="mydate.htm">mydate</a>'); document.write('<a href="mytime.htm">mytime</a>'); The mydate mytime.htm are the pages that tell that the browser settings is what controls the time and date, would this work for accomplishing this task 7.I did a full math function doing today = new Date(); document.write(today); and it brough up the full time and date, and everything, but most tutorials use all the getTime, getFullYear, and getDate, why don't they just do what I showed above, is there other way better for some reason.
  4. Hmm, ok so that clears that up, so I know what a template is, by what I have read a template is simply one php script that is a master script to a lot of sub scripts. It is something that allows you to change a bunch of php scripts over a broad range of pages through just one script, what I don't understand is sometimes designers say theya re going to create a website, and a control panel for the client to log in to and control his site, without having to touch the code, what is that, and is it something I could program myself, is it made entirely in php.
  5. I will take both of your ideas into consideration, I thank both of you for the advice, the way I like doing something is getting my hands involved a little bit in everything. So I will make sure that I try out both ways numerous times and learn which way is better. I had another question and don't want to crowd the forums, so I am going to ask it here. I have heard a lot about 2 things. cms, and gui interface. I know one of these has something to do with creating a control panel or something along those lines for a client to be able to easily update his site. What exactly is it, I picture a control panel like for a web hosting company where they can control all aspects of the site. But what confuses me is I have heard of templates, Where you have a master php script, that controls duplications of php scripts, so you can change them all at once ,I like the idea but don't have a need for that until I start doing major scripts where scripts appear in multiple places, if ever, but what is the difference between templating and gui(if gui is the process of creating the control panel). THis has been confusing me, I was wondering is the gui control panel the same as create a newsletter control panel, is it just a web page that has xhtml, css, and php that have a lot of forms that the owner of the site can control various aspects of the page, or is it an actual program not created in php that is used to mantain the site, like contribute, I wanted to know because for most clients, if they have contribute I can tell them they can update it through there, I use dreamweaver code view all the time, but I can tell the client if they have dreamweaver that is where they can take care of there site from in design view. And if they have frontpage they could change the text around probably with out destroying the coding, but the gui interface(if that's what the control panel is) is confusing me, and I have looked all over the place trying to find informationa bout it. And the main question I have is this something I can program myself, or do I HAVE to buy a 3rd party something to get it done. I like programming everything myself if it is possible, unless it's something major like a huge forum or something.
  6. I wasn't intending on sending it html format, but the thing about the pdf how do I set that up. I mean does it send it in an email as an attachment, because I want to avoid that, or does it send the PDF, to where you can read it in the email, and also not everyone has a pdf reading, that is what is confusing me on this specific idea.
  7. Sounds good I have a thourough grounding in some steps to follow to get this accomplished I apprecaite all the help thanks.
  8. That makes sense, but I am unfamiliar with pdfs, I will keep that in mind, after I hear thorpe's idea one more time then I am going to get started on this either way.
  9. PERFECT that was what I was wondering. So this should be the whole process. I have a form, with 1 text field and submit button, this gathers the emails. Or actually 2 buttons, subscribe unsubscribe, if they subscribe it adds the email to the database, if they unsubscribe it it takes it out. Then I have it database that information. Then I create another form, to where he puts in all the information he wants to send in the email and hits send, then I have to send an email to everyone in the database from there. That is perfect, 2 more questions and I am ready to start. 1. Do I create the newsletter admin page on his server, but just don't link it to his site, and give him the url, like that, because I have never seen anything like that linked to a site before. 2. How would I accomodate the form to be able to accept pictures. He wanted to have like a picture of his book at top, then some information regarding the book, in his first newsletter, then whatever else in future ones. edit- I meant I didn't understand what lite said, that specific part, was a little deep.
  10. That is a little over my head, I am confused about the part where you stated. [!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]Design it so the client only has to do 1 thing - create the newsletter[/quote] How do I get him to create the newsletter. That is the part that is confusing me.
  11. By looking at that, it tells me that it is pulling the emails from the database, then send the email, I understand all that, it's just about the issue of getting the client access to that, My client, the one the site is being built for doesn't understand php. I need to figure out where HE can send the email from. How do I set that up, I thought about a form, where he can just type out the newsletter, click submit and it sends it to all of them, but I have never seen another site do that before, unless they don't link it to the main site, do you understand what I mean.
  12. I mean my client. Here is the thing, someone wanted me to build a site, no problem, they wanted a newsletter, to where people could sign up for the newsletter, this entails getting email address saved to a database, easy. But then I get down to trying to figure out, there has to be a way for my client, the one who will be owning the site, to be able to email all the people that sign up for the list. I have looked at other peoples websites and never saw anyone with an area on there websites for them to send emails to people on there mailing list, I am wondering how this is done, or how I set something up.
  13. This is helpful for something to look at, and if I get too bogged I will switch to this, but I want to get better at programming, now i am far from a beginning, I just need to learn how to put this together. I was finally pointed in advice earlier from someone on the components I need to program to send an email massly, but there is one thing I don't understand, how do I get my client access to where he can send the email, I could put a page on the server, that is password protected where he could send out bunches of emails. But what I don't get though is I have never seen another site do that, to where they have a place where the client logged in to send the emails. What is the best idea for me to set something up so he can get the emails to send.
  14. That's not the part I am confused about, I guess I misworded the question. What I need to know is how to get it to where my client can email people I know how to collect the information about the mailers, but I am confused about how to set it up to where the client can actively create and send a newsletter out to all the people.
  15. I have been looking around and I saw something like Mailing List Managers, is this something I can program myself, or something I have to find in a script, how do I create my own mailing list manager.
  16. That sounds good, how do I set up the situation where they can email the person back. I know how to create mail scripts, but I have to put in the information for it to mail, and I know how to process/validate forms of any manner/size. But what I am trying to figure out how to do, is set it up to where the emails can get sent out, or do I just gather the emails, and then have him send the emails through his email address, these are the details I am trying to work out, but what you said was very helpful I will keep all of that in mind when I start building it.
  17. I know php programming very well, but I am unfamiliar with the act of programming a newsletter. A place where people sign up, and have it add it to a list, and automatically send a list to a bunch of people when the site own gets ready, looking at other newsletters all I see for the form action goes to a php script that mails it to the site owner, what do they do with the email after that. Programming is funer than grabbing a renegade 3rd party script for everything.
  18. I am about to start a site creation for someone, he is wanting a newsletter on his site, where he can put what he needs to into it, and have it send to whoever he needs. Is it better to use a 3rd party script or create one from scratch, the project is for 500 for a site creation, recreating his old site, about 5-8 pages, and that's it, this is a challenge because the site is about something I know nothing about, but I have past content to go on, it's just the newsletter is what is making me wonder.
  19. First of all hardwiring is specifically the way I talk. Second of all I wasn't asking someone to do the script for me, I did the whole thing myself, all I was asking for was a little help understand understanding where to put newline characters and other punctuation, and I specified the areas, the places that you add in stuff to the message, with the implode, to all the different sections of message, I wanted to be able to put in the radio buttons, and select boxes, so I can see it in the email, I am having a hard time "hardwiring" it into the message.
  20. Parse error: parse error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING in /home/freelan4/public_html/cgi-bin/form-processors/projectinformationprocessor.php on line 51 that is one of them. My problem is, I don't know how to "hardwire" something into a variable, I had the message right, but when I started adding in the extra fields like the radio buttons and select boxes, it started having errors, I don't know where to put those /n's and . and " and all that stuff. I have problems before some people throw in some punctuation marks and all of a sudden BOOM it works, no problem. But when I try to do it, it always messes up.
  21. This isn't working, I am just wondering if theres any errors in the code, it is just having different errors The form is below, that processor and validator below that. I have done this once, but now with checkboxes and radio buttons, and it's not passing through. [code] <form onsubmit="return submitcheckproject()" name="projectinformation" action="../cgi-bin/form-processors/projectinformationprocessor.php" method="post"> <fieldset class="formstyle"> <legend>Project Information</legend><br /> <label for="firstname" accesskey="f">*First Name:</label><br /> <input tabindex="1" name="firstname" id="firstname" type="text" maxlength="30" /><br /> <label for="lastname" accesskey="l">*Last Name:</label><br /> <input tabindex="2" name="lastname" id="lastname" type="text" maxlength="30" /><br /> <label for="age" accesskey="2">Age:</label><br /> <input tabindex="3" name="age" id="age" type="text" maxlength="3" /><br /> *Sex:<br /> <label for="male"><input name="sex[]" id="male" type="radio" value="male" checked="checked" />Male</label> <br /> <label for="female"><input name="sex[]" id="female" type="radio" value="female" /> Female</label><br /> <label for="operatingsystem">*Operating System</label><br /> <select name="operatingsystem[]" id="operatingsystem"> <option>Unix</option> <option>Windows</option> <option>Linux</option> <option>MacOs</option> <option>Other</option> <option>Don't Know</option> <option>Not Application</option> </select><br /> <label for="serverside">*Server Side</label><br /> <select name="serverside" id="serverside"> <option>Java Server Pages/jsp</option> <option>Hypertext Preprocessor/PHP</option> <option>Active Server Pages/ASP</option> <option>Cold Fusion/CF</option <option>Server Side Javascript</option> <option>Other</option> <option>Unknown</option> <option>Not Applicable</option> </select><br /> *Does Your website have/will have a database:<br /> <label for="yes"><input name="database[]" id="yes" type="radio" />Yes</label><br /> <label for="no"><input name="database[]" id="no" type="radio" checked="checked" />No</label><br /> <label for="databasetype">*What database server:</label><br /> <input name="databasetype" id="databasetype" type="text" maxlength="80" /><br /> <label for="emailaddress" accesskey="e">*Email Address:</label><br /> <input tabindex="4" name="emailaddress" id="emailaddress" type="text" maxlength="80"  /><br /> <label for="verifyemail" accesskey="v">*Verify Email:</label><br /> <input tabindex="5" name="verifyemail" id="verifyemail" type="text" maxlength="80" /> <br /> <label for="computerknowledge" accesskey="c">*How much do you know about computers in general:</label> <br /> <input tabindex="6" name="computerknowledge" id="computerknowledge" type="text" maxlength="80" /> <br /> <label for="languageknowledge" accesskey="l">*Put the computer languages you know, with your level of experience in each one:</label><br /> <input tabindex="7" name="languageknowledge" id="languageknowledge" type="text" maxlength="80" /> <br /> *Is there a deadline associated with this project:<br /> <label for="yes"><input name="deadline[]" id="yes" type="radio" value="yes" />Yes</label><br /> <label for="no"><input name="deadline[]" id="no" type="radio" value="no" checked="checked" />No</label><br /> <label for="timelimit">*If so what is the time limit, if not applicable, just put none:</label><br /> <input tabindex="8" name="timelimit" id="timelimit" type="text" maxlength="30" /><br /> <label for="projectrelation" accesskey="t">*What is the project related too:</label><br /> <input name="projectrelation" id="projectrelation" type="text" maxlength="80" /><br /> <label for="description" accesskey="d">*Description:</label><br /> <textarea tabindex="9" name="description" id="description" rows="6" cols="30"> </textarea><br /> <input tabindex="10" name="submit" id="submit" type="submit" value="submit" /> <input tabindex="11" name="reset" id="reset" type="reset" value="reset" /> </fieldset> </form> [/code] Below is the processor and validater [code] <?php if ($_POST['firstname'] == ""){ print("Please go back and fill in the first name field correctly"); }elseif ($_POST['lastname'] == ""){ print("Please go back and fill in the last name field correctly"); }elseif ($_POST['age'] == ""){ print("Please go back and fill in the Age field"); }elseif ($_POST['databasetype'] == ""){ print("Please go back and fill in the Database Type Field"); }elseif ($_POST['emailaddress'] == ""){ print("Please go back and fill in the Email Address field"); }elseif ($_POST['verifyemail'] == ""){ print("Please go back and fill in the Verify Email Address field"); }elseif ($_POST['emailaddress'] != $_POST['verifyemail']){ print("Your email Address fields DO NOT match, please correct this"); }elseif ($_POST['computerknowledge'] == ""){ print("Please go back and fill in the computer knowledge field"); }elseif ($_POST['languageknowledge'] == ""){ print("Please go back and fill in the Language Knowledge field"); }elseif ($_POST['timelimit'] == ""){ print("Please go back and fill in the Time Limit field"); }elseif ($_POST['projectrelation'] == ""){ print("Please go back and fill in the project relation field"); }elseif ($_POST['description'] == ""){ print("Please go back and fill in the Description field"); }else { $firstname = $_POST['firstname']; $lastname = $_POST['lastname']; $age = $_POST['age']; $databasetype = $_POST['databasetype']; $emailaddress = $_POST['emailaddress']; $verifyemail = $_POST['verifyemail']; $computerknowledge = $_POST['computerknowledge']; $languageknowledge = $_POST['languageknowledge']; $timelimit = $_POST['timelimit']; $projectrelation = $_POST['projectrelation']; $description = $_POST['description']; $to = "businessman332211@hotmail.com"; $subject = "Project Information"; $message = " First Name: $firstname Last Name: $lastname Age:" $message .= "implode(', ',$_POST['sex']); Operating System:" $message .= "implode(', ',$_POST['operatingsystem']); Server Side:" $message .= "implode(', ',$_POST['serverside']); Database Type: $databasetype"; $message .= "implode(', ',$_POST['database']); Email Address: $emailaddress Verify Email: $verifyemail Computer Knowledge: $computerknowledge Language Knowledge: $languageknowledge"; $message .= "implode(', ',$_POST['deadline']); Time Limit: $timelimit Project Relation: $projectrelation Description: $description "; if(mail($to, $subject, $message)) { print("Thank you for submitting your email has been successfully sent"); print("<br />Return to the homepage at <a href='http://www.freelancebusinessman.com'>Freelance Businessman</a>"); }else{ print("I am sorry but there was some sort of error and the email could not be sent"); print("<br />I am not totally sure of the cause of this error."); print("<br />Please return to <a href='http://www.freelancebusinessman.com'>Freelance Businessman</a>"); print("<br />If you try again and recieve this error message a second time, then please email me at the original email address and notify me of this error, so it can be checked into.  Thank you for visiting Freelance Businessman."); } } ?> [/code] any help would be appreciated, I have 1 hour left to work, thanks.
  22. I'll take what you gave me and play around with it, see what I can come up with thanks. I don't know much asp, I am planning on only learning it enough to get by when a client needs something done. Php is my pride and joy, it's funner than any other server side languages I have played with. I have moved on now to trying to javascript validation, I am getting better at programming overall lately.
  23. The thing I don't understand is, now that I worked with it, I have the answers completely, it validates and processes on an external page. But I didn't need to do anything with repopulation. When they hit the back button it automatically still has the info in the slots, that is confusing.
  24. Thanks, that finally got everything working on that, and gave me something to look at in the future when I am doing things with these as well, thanks again for the help.
  25. Sorry for yet another post, but I ran into a problem, that seems to be related to php. I don't understand this. Ok I have showed my form before, Here is my code [code] <?php if ($_POST['firstname'] == ""){ print("Please go back and fill int he First Name field correctly<br />"); }if ($_POST['emailaddress'] == ""){ print("Please go back and fill in the Email Address field correctly<br />"); }if ($_POST['verifyemail'] == ""){ print("Please go back and fill in the Verify Email field correctly<br />"); }if ($_POST['description'] == ""){ print("Please go back and fill in the Description field correctly<br />"); }if ($_POST['emailaddress'] !== $_POST['verifyemail']){ print("Unfortunately the email addresses did not match, please recheck what you put"); }else { $firstname = $_POST['firstname']; $emailaddress = $_POST['emailaddress']; $verifyemail = $_POST['verifyemail']; $description = $_POST['description']; $to = "businessman332211@hotmail.com"; $subject = "ideas and submissions"; $message = " First Name: $firstname Email Address: $emailaddress Verify Email: $verifyemail Description: $description "; if(mail($to, $subject, $message)) { print("Thank you for submitting your email has been successfully sent"); print("<br />Return to the homepage at <a href='http://www.freelancebusinessman.com'>Freelance Businessman</a>"); }else{ print("I am sorry but there was some sort of error and the email could not be sent"); print("<br />I am not totally sure of the cause of this error."); print("<br />Please return to <a href='http://www.freelancebusinessman.com'>Freelance Businessman</a>"); print("<br />If you try again and recieve this error message a second time, then please email me at the original email address and notify me of this error, so it can be checked into.  Thank you for visiting Freelance Businessman."); } } ?> [/code] This is the problem. At first it wasn't sending the email, when I just had the email command in there, I got it working, then I incorporated the validation, and got it working, but it would validate it and send it anyway, then I formed the code as shown above, it worked, except for the last if statement, for instance, before it worked, but I added that last section [code] }if ($_POST['emailaddress'] !== $_POST['verifyemail']){ print("Unfortunately the email addresses did not match, please recheck what you put"); }else { [/code] when I added this last line of code it stopped working correctly and now again it started doing that, it started automatically sending the email and validating it at the same time, am I limited to how many if statements I can put before the else statement, or did I do it wrong somehow.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.