Jump to content

jherzog

Members
  • Posts

    18
  • Joined

  • Last visited

Everything posted by jherzog

  1. Does anyone know of a good article that explains the security risks of using register globals in laymen terms. I need to understand more and be able to explain it to those people who don't have coding knowledge. Thanks again for your help.Jed
  2. Yeah that is what I have been reading. Thank you.Now I have the task of adding the code to all the pages that receive variables. A problem is that this site is extensive and I did not write the code. Therefore I am not sure which pages are receiving variables nor what those variable’s names are. It is going to take a lot of combing to confidently find all those instances. Is there a catch all PHP command that retrieves any sent variables. Since I am having a hard time wording my question let me say it a different way.Is there a php command I could put at the beginning of most of my pages that would retrieve all GET or POST variables that have been sent to it? Hence avoiding the need to writing out $varname = $_GET['varname']; for every variable. Thanks for any help
  3. I am suffering a php problem the I don't quite understand and was hoping some one could clearify it for me.Many of the pages in a site receive a variable via the URL (GET method) (ie. www.url.com?variablename=variablevalue). But these pages do not contain specific code to retrieve these variables (ie. $pagevar = $_GET['variablename']. Regardless of not having this specific retrieval code all the pages worked jsut fine and now do not. Something must have changed at my hosting company. I think this has to do with the issue call globals or superglobals but I don't understand exactly. Any idea what changed, and if there is a helpful solution? This site is large and it would be extensive to identify and edit everypage that retrieves a variable but is missing that code. More general I would just like to know more about this issue. Thank you for your help.Jed
  4. Is there a php command that would return the dimensions of an image file?This file is saved in a directory not in a database.I have looked at the function stat() which returns a lot of information on a file but does not return dimensions (which would be specific to image files).I will explain why I want this in case there is an obviously better solution that you know about:I have a page that displays a picture. In theory all of these pictures should be less then 200px wide or they mess up the layout. However, I am building this site for people who are not web/tech savvy. If they were to upload a picture that was too large I don't want it to display. I was thinking an if() test to make sure that the picture is less then 200px wide. But I can do this only if I can retrieve the dimension stats from a file. Since the proportions of all these pictures change I can not define the image dimensions with html (ie width=200px height=200px). If the pictures proportions were not 1 to 1 the image would be distorted. Another reason I can't define the dimensions with HTML is there could be pictures less than 200px wide which I don't want to blow up, I want them to stay smaller. So that is my problem. Again a php function that returns dimensions would be cool but I kind of doubt it exists. Any ideas?Jed
  5. I code in php and use MySQL databases. I am taking on a client which will include moving his web site to a new host company and coding future products. Parts of his existing site are written in ASP.net and require a SQL database. Is it possible to host on a server that can do all of this: PHP, MySQL, ASP.net, & SQL?My understanding is that it is either or, not both. Microsoft servers run ASP.net/SQL and linux servers run PHP/MySQL. Let me know what you know.Jed
  6. I am looking at some code that includes a tag<csobj w="929" h="60" t="Component" csref="../URL.data/Components/copyright.html" occur="0">It seems this tag does nothing. A google seach on it implied it was part of a scripting lanuage called Cscript but couldn't find anything else out. There is not a scripting language referenced in the headers. Does any one know what this tag is?
  7. jherzog

    405 error in PHP form

    The code you posted above does send your form information to a php page called feedback.php.Without more information I don't know what that page is suppose to do with the information. What is the purpose of this script. Are you sending the comments to a database, generating an email?
  8. I am taking over maintance of a site I did not build. It was built using Frontpage which I am unfamilar with. When I create a form and submit it via the GET method, there are addditional variables that are sent. Additional variables meaning variables without values appear in the url that I did not set up in the form.Does anyone know where these are coming from. I have searched the page html code for them and did not find them?Thanks for any help.Jed
  9. jherzog

    405 error in PHP form

    Although I have run into this problem and solved it via using the get method verus the post method, I was wondering if anyone else knows how these methods are banned and/or how to change it. Are these settings that can be set in a .htaccesss file or anything like that.
  10. jherzog

    405 error in PHP form

    The post method submits your form info into the next page invisibly to the web user. The get method submits your form info to the next page using the url address. You have proabably seen many pages who's addresss looks like http://www.domain.com?variable=33&name=john&etc=otherstuffAll of the "?variable=33&name=john&etc=otherstuff" stuff on the end of those addresses are form information being passes along automatically by the get method of html forms.So to try this fix, just change the first line of your script to <form action="feedback.php" method="get">You will also have to check your page feedback.php. It may have lines retrieving the form info. Those commends look something like "$variable = $_POST['Comments'];". If that feedback.php page does contain these commands you need to change POST to GET. ($variable = $_GET['Comments'];Let me know if you have additional questions.
  11. jherzog

    405 error in PHP form

    Is it a priority to sumbit your form via the post method? Do you know the difference between post and get (not tring to insult, I am just not sure of your level of php knowledge). Some php servers disable the post method for security reasons. Usually in that case the get method is still allowed. Let me know if you want more details on this option
  12. I have had the problem before myself and never found a solutions. This was the most enlighting article I found at the time. I hope I am not violating a rule by posting another page here but it does go into this subject in depth.http://www.quirksmode.org/css/100percheight.htmlJed
  13. jherzog

    Div inside Divs

    Thanks guys for all of the suggestions. You certainly lead down the correct path. My ideas of what absolute and relative position was not exactly right. I have read up on it now.I have another follow up question. The min-height feature is quite handy, in fact becoming nessecary as this site develops. I now have a section that has to streach to fit whatever its contents might be but also must have at least a minimal height. However IE doesn't recognize this min-height attribute. How do you work around that?Jed
  14. Yeah I am not sure if I can help you any further. I am certainly not as skilled in PHP as some. If you want the scipt to automatically write a file to your HD (verus the web server's drive) I think you might find that hard to impossible (I think, I don't know). I could see security issues if scripts were able to do that. You could write a cookie which is a text file but then it will go to the cookie folder. Sorry I couldn't help more, hopefully someone more skilled with join the discussion.
  15. whoops I called your variable value not your variable name. So the fourth line should be: $body=$_POST['s'];
  16. Is this something you want the script to do automaticly? If you want the user to be able to choose the path to save the text file you can do something like this:<?php //Retrieve your variable to make the body of the text file $body=$_POST['TrResult']; //This header designates that the page is a text file for download header("Content-type: text/plain"); //This header names the file header("Content-Disposition: attachment; filename=filename.txt"); header("Pragma: no-cache"); header("Expires: 0"); //The following print function will create the body of the text file print " $body ";?>Going to this page will present the user with a "Save as" box and allow them to save the file where they normally would. The file is a plain text file with the name you designate on line 9.Not sure if this is what you wanted, let me know.Jed
  17. jherzog

    Hello

    Hello All, I have used W3School website many times but just joined the forums. I look forward to working and sharing with you. If I may, let me introduce myself. I am currently a marketing manager for Outlier Solutions Inc. Marketing http://www.outliersolutions.com in Portland Oregon.Outlier Solutions Inc. is a full service marketing firm. Our focus is on leveraging technology to create stronger brand awareness, support lead generation, and aid in product training and promotion. Outlier Solutions offers a full range of marketing services and products to enhance one's marketing arsenal. This includes web marketing, web site design, print collateral, brochures, public relations, graphic design, search engine marketing, and video production.If anyone shares similar interests I would enjoy colaborating in an effort to further of our our skills and knowledge. Thanks.Jed Herzog
  18. jherzog

    Div inside Divs

    Okay I am experienced with HTML and have used CSS for basic formating purposes for sometime. It has been suggested to me that I move from using HTML tables to CSS for page layout purposes. I am experiencing some issues that imply I don't know CSS well enough to impliment this fully. Which leads to my question (probably my first of many ).I have set up a Division(Div) and I want its height to adjust automatically to fit all of the content inside of it. However, the content inside of this division is other divisions. The First div seems to ignore these other divisions and there for has a height of zero. Is this true? Any suggestions or what to do? Is there a good resource to teach one how to fully use css specifically for page layout and positioning?Here is a very quick and basic example of what I am doing:<body><html><head><style type="text/css">div.1{height:auto;background-color:#000000;}div.2{position: absolute;top:10px;left:10px;width:10px;height:50px;background-color:#ffffff;}</style></head><body><div class="1"> <div class="2">This is a white text box defined in Div 2. Yet since it is also inside Div 1 the page should have a black background as high as this text box, right? </div></div></body></html>
×
×
  • Create New...