iwato

Members
  • Content count

    705
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by iwato

  1. <?=++$a?> <?=++$b?> <?=$private_id?> <?=session_id()?> I found this on the internet amongst some other code, and it appears to work. Unfortunately, I do not quite understand it. Is <?= a shorthand for <?php echo ... ;
  2. Understood. But, pages with .php extensions can display HTML. One of my pages displays no HTML, the other does. This is what I meant. Thank you. Roddy
  3. THE TASK: Receive an HTTP query from an external source. Use the information from the query to obtain information from a data base Insert the information from the database into a filler page. Load the filler into the host page in such away that both appear simultaneously. DILEMMA: I can perform all of these tasks individually, but I am at a loss as to how to move from Step 3 to Step 4. DISCUSSION: I am accustomed to loading a filler into a page that is already opened. And, I am accustomed to loading a page with information queried from a database. Although I am pretty sure that I can call a page and load it with a filler whose content is determined by the HTTP query (Steps 1 and 4). What I have not done and feel awkward about is filling the filler page with information from the database query before displaying both the page and the filler together. QUESTION: Any suggestions? Roddy
  4. It will be my first time to use a session, but I could see the time coming long before I started the current task. So, now is just as good as time as any, and it looks like using a session will provide me with all of the communication that I need between the PHP and HTML pages. Once again, Dsonesuk, you have struck home. Many thanks! Roddy
  5. I have just discovered that I can use the PHP header( ) function with an URL as the value of the function's location parameter to open the HTML page from the PHP age. header("Location: $url"); Ostensibly, i could append a query string to the end of the URL and then process this string on the HTML when the page opens. Would this not require, however, that I change the extension of the HTML page from .html to .php? Likely not a big deal as the HTML page is still in a stage of development. Roddy
  6. The user will click on the third-party website only if he wants. That is his choice. i only care about what happens after he clicks. Yes and no. Yes, when the user clicks on the third party website, he is taken to my website, but his action does not open an HTML page, rather an invisible PHP page. What I need to know is how get this latter page with the .php extention to open an .html page in the user's browser after it has processed the information sent to it from the third-party website. In addition, I would like that the information processed on the PHP page be transferred to the newly opened HTML page. Is it clear now? Roddy
  7. OK. We appear to have touched base here: If you're saying the page isn't loaded by the browser yet, then nothing can happen until the browser sends a request for the page and gets a response from the server. So, I have to 1) Get the PHP page to send a request to the user's browser to open the host HTML page. 2) Force a request from the newly opened HTML page to the PHP page. 3) Receive the response and display it in the HTML page. This looks like AJAX. Something that I have never used before, but appears entirely within my reach as I have some knowledge of both Javascript and JSON. This appears to be something that I can do except for the fact that I do not know who the user is. Once again, The TASK The user clicks on a link on a third party website. An HTTP request is sent from the third party website to a PHP document hosted on my own webpage that uses the requested information to query a database and make a determination. But, how does the PHP document know where to send the HTTP request necessary to open the host HTML page in the user's browser? Roddy
  8. Let me try one more time. Usually, information from an external source is loaded into an HTML page that is already opened. In my case, the HTML page in which the information is to appear is not yet opened. What is more, the unopened page in which the processed information is to appear is used for several other purposes and cannot be easily produced from the processing PHP page that produces the information that is to appear in the HTML page. Roddy
  9. So as to be simpler. QUESTION ONE: Is it possible to call a page into which the calling page is itself loaded? QUESTION TWO: If this is possible, there is likely more than one technique available to achieve the task. What are they?
  10. JSG: I have created a form page (sender.php) with a single input field. The value of this input field is sent via a $_GET superglobal to another page (receiver.php) that: one, retrieves all of the records from a data base; two, compares the value received from the form page (sender.php) with the values of a field of all of the retrieved records, and three, displays the receiver.php page with the value of another field of the same matched record. Everything up to this point has now been accomplished. JSG: Indeed, this is the part that I have yet to overcome. The displayed result (see above) is the information that should serve as a filler for another page that hosts all such form queries. QUESTION: How do I get the information from this filler (receiver.php) to appear in the host page with the host page when the result of the form query is sent to the filler template? Roddy
  11. Thank you for responding. I have decided to play with my idea a little before coming back. For, in this way, I will be able to ask a better question dealing specifically with code. In so doing, I may even be able to answer my own question.
  12. OK. As always -- well, almost always -- you make good sense, and I like it. Is the $_GET variable not automatically created when a query string is sent, though? PHP is simply used to process the data that the variable contains. Or, have I misunderstood. Now, to the further strategy. The model that I want to use is the one that you taught me when I wanted to view the PHP source code of one page by clicking on a link contained in another page. In other words, click on a link on one page, send a query to another page, receive the query, make a choice with a SWITCH statement and display the desired page of code in the same window that was once filled with PHP code containing the SWITCH page . This time, however, rather than displaying PHP code I want to display the contents of an HTML page. Where I am unclear is how best to display the contents of the HTML document as content in another HTML page. The destination for the content is the main section of the following page http://www.grammarcaptive.com/podcast_dev_copy.html. Now, I have filled such space in the past by a variety of means including: 1) Hiding content already on the page and then making it appear. 2) Replacing it with a portion of another page that I have fetched with the Javascript .load( ) method. 3) Replacing swapping the content of an iframe. Of these three approaches I prefer number two, because I fill the section with whatever I want. The problem, as I imagine it, occurs, when I try to automate the process. Using an iframe would be easy, because the iframe would simply fill with the content generated from HTTP query. But, the procedure would only work so long as the page that receives the query and the iframe itself were present when the query were made. What would happen, if the page were filled with something else when the query is made. Also clicking on a link hosted on someone else's page would automatically force a new page to open. I would not want my user to be opened to the same page twice. Can you help me think this through. Have a provided enough information? Roddy
  13. OJBECTIVE: My goal is to send a $_GET or $_POST variable from an RSS feed when the user clicks on a link housed within the <description> subelement of an <item> tag. The data from the superglobal will be used to display content on a host webpage designed as an index for all <item>s hosted within the same and ultimately other channels. CODE SAMPLE: <item> . . <description>Grammar Captive Free Weekly Podcasts: <![CDATA[<a href='http://www.grammarcaptive.com/podcasting/podcasts.php?episode_no=003' title='Episode Title' target='_self'>Episode No. 003</a>]]></description> . . </item> QUESTION: Will by placing the link with the intended address and appended http request code into a CDATA tag allow users to send the desire episode number to the designated PHP page for processing. ADVANCED STRATEGY: If the above is possible, do you have any suggestions in regard to the best way for the receiving PHP page to call up the material relevant to the designated episode? For example, I am contemplating the use of a SWITCH statement that would route the incoming episode number to a block of PHP or Javascript code that would insert the contents of another webpage, whose URL is the episode number of the incoming HTTP_REQUEST, and whose content is dedicated to the episode corresponding to the incoming episode number, into another webpage (likely the same page that contains the SWITCH statement) that serves as an index for all completed and upcoming episodes. Roddy
  14. Got it. Dsonesuk, you are one very knowledgeable individual. It turns out that the 2nd and 3rd media rules were absolutely useless with regard to the desired flex box effect, and as you wisely suggested the column direction setting is completely unnecessary. For others, however, you might wish to direct them toward Firefox's Responsive Design Mode. For in this mode the screen width is counted for you, and you can watch the behavior of the window's contents as the width is being counted. What is more you can set the width in the same window mode to the precise location that the change needs to be made. It is a super tool; for it taught not only where the changes were taking place, but also where I needed to place the flex box display property to attain the desired affect. (Firefox / Tools / Web Developer / Responsive Design Mode) Have a great day! Roddy
  15. BACKGROUND: I have recently created a new page based on code used on another page that appears to be functioning well. As the content is different, however, it was necessary that I make several important modifications. Still, the basic format is the same, and I do not understand why the new content is not responding as it should. As always, I have tried a variety of experiments before coming to you including resetting the values of the width property of both the media rule and the media rule's content, reordering the script order of both the imported CSS files and their content, as well as the placement of the CSS rules that command the flex-box. My CSS selectors appear to be appropriate as I am able to generate change. Unfortunately, the desired change is not the change that I am generating. QUESTION: What is the most likely cause of the dysfunction? ORIGINAL PAGE: Observe the behavior of the pages navigation bar, main section, right sidebar, and footer as the size of your viewport expands and contracts. On my devices (iMac, MacBook, and iPhone) the behavior is the desired behavior. The various section appear to function well no matter the selected browser. http://www.grammarcaptive.com/overview.html NEW PAGE: Although the main content section is empty, the right sidebar does not function as intended under the second media rule -- this, despite its proper functioning under the first and third rules. http://www.grammarcaptive.com/podcast_dev_copy.html NOTE: I'll not place any code as everything is easily viewed online.
  16. Yes, but what could be preventing the column of images from becoming a row, when the right column no longer fits in the viewport and is compelled to align underneath the left an middle panels? What is more, why would the column switch to a row only when the header, left panel, main content panel, and right panel are aligned vertically, and not before? After all, the row setting is occurs with the second media rule. The combined width of the left navigation panel (200 px), main panel (504 px), and horizontal margins (10 px) is 714 px. The second media rule should kick into effect as soon as the viewport reaches a width of 700 px. Notwithstanding, no matter the size of the max-width, be it above, below, or exactly 714px, the result is the same. What is more, there is no CSS below the rule that obviously affects the size of the viewport or the panels in question. I simply do not get it. Roddy
  17. The direction is set as column only for the first media rule. For the second, and therefore the third as well, the direction is set to row. Take a closer look at podcast_template.css. Roddy
  18. Thank you for responding. I was beginning to think that no one cared. The result of the second media rule should be the same as the third. As the viewport contracts the column simply shifts from the right of the main content to below it. When it moves below it should turn into a row that wraps, as it finally does well all parts of the document are stacked on top of each other.
  19. If it would encourage a response, I have since cleaned the file of potential noise that could have been getting in the way.
  20. Please delete this entry so that it is not confused with the entry correctly listed in the CSS forum. Thank you!
  21. BACKGROUND: I have recently created a new page based on code used on another page that appears to be functioning well. As the content is different, however, it was necessary that I make several important modifications. Still, the basic format is the same, and I do not understand why the new content is not responding as it should. As always, I have tried a variety of experiments before coming to you including resetting the values of the width property of both the media rule and the media rule's content, reordering the script order of both the imported CSS files and their content, as well as the placement of the CSS rules that command the flex-box. My CSS selectors appear to be appropriate as I am able to generate change. Unfortunately, the desired change is not the change that I am generating. QUESTION: What is the most likely cause of the dysfunction? ORIGINAL PAGE: Observe the behavior of the pages navigation bar, main section, right sidebar, and footer as the size of your viewport expands and contracts. On my devices (iMac, MacBook, and iPhone) the behavior is the desired behavior. The various section appear to function well no matter the selected browser. http://www.grammarcaptive.com/overview.html NEW PAGE: Although the main content section is empty, the right sidebar does not function as intended under the second media rule -- this, despite its proper functioning under the first and third rules. http://www.grammarcaptive.com/podcast_dev_copy.html NOTE: I'll not place any code as everything is easily viewed online.
  22. Yes a function was being called for which there was no longer a reference. I was not terribly thorough in the deconstruction of the page before I began rebuilding it. I usually catch this sort of things at the end, unless, of course they cause trouble along the way. In this case i removed the function call, but the problem with the media rule persists. In any case, thank you.
  23. JSG: Thank you for the heads up. I did not realize that I had posted this query to the XML forum and have moved it to the CSS forum where it belongs. I do not understand why one of the pages did not open, though. I just tried both of the links, and they were working fine. Please delete this entry. I apologize for the misplacement. Roddy
  24. Thanks, Ingolme!
  25. BACKGROUND: I have recently created the content of an automatically generated podcast using a PHP Class that I found on a webpage found https://www.phpclasses.org/package/2957-PHP-Generate-RSS-2-0-feeds.html. Unfortunately, when I attempt to display the generated feed all that is displayed are the values of the input variables, or alternatively nothing (see (below)depending on the method of display. In short, the desired formatting -- the reason that I downloaded the PHP Class -- is missing. The page that creates the above result is a text file with a .php extension and a header( ) function. $rss_feed->encoding = 'UTF-8'; $rss_feed->version = '2.0'; $rss_feed->createFeed($rss_channel); header('Content-Type: text/xml; $rss_channel = the object that combines the formatting with the values of the input variables and their respective objects. The Class is relatively straight-forward and easily customized, but for two lines that I do not understand and could well be preventing the display of the XML code, if not properly configured. Interestingly, whether they are commented out or left in tact, they have no affect on what is displayed. $selfUrl = (!isset($_SERVER['HTTPS']) || $_SERVER['HTTPS'] != 'on' ? 'http://' : 'https://'); $selfUrl .= $_SERVER['HTTP_HOST'] . $_SERVER['PHP_SELF']; When I run the .php file the following message appears at the top of the completed page. Still nothing below the message appears. Also, I do not know the source of this message. it does not appear to come from the .php document. Now, I have not constructed a style-sheet for the Feed page, but I hardly see how this could stop the feed from appearingl Please advise.