Sponsored Content
Top Forums Web Development How to create a link that will display the contents of a PHP variable? Post 303012819 by Corona688 on Friday 9th of February 2018 05:57:31 PM
Old 02-09-2018
Quote:
Originally Posted by crimso
Correct, I could but this a PHP script that is in the machine's /var/www/html directory that you point your browser at.
Yes, it is; I'm not sure how this prevents you from printing something.

Your PHP script - and most other CGI scripts like it - don't interact with a web browser in real-time, it runs once on page load then quits. Your program has already quit by the time someone is looking at its output, and clicking would either cause another page load (of the same script or a different one), or trigger something to happen in the page's HTML, or execute a javascript program.

The simplest way would be to use HTML expanding sections, like this:

Code:
<details>
    <summary>Clickable Part</summary>
    Hidden Part
</details>

 

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

How to display contents of folder when 'cd' is used

Hi, I am a new learner of Unix. I am currently working on a Solaris 8 machine. Earlier, when I use 'cd <folder name>' command, I am not only able to change the folder but also able to see the contents of the folder as if a 'ls -lt' command was executed. However, since a week, suddenly this... (3 Replies)
Discussion started by: mumashankar
3 Replies

2. UNIX for Dummies Questions & Answers

Display the contents of an array

Hi i have just registered So i am at university studying forensic computing and we have to learn c++ i have never done anything with c++ before and i am abit stuck i need to create a programme to display the contents of an array of characters forwards and in reverse Can anyone help me... (1 Reply)
Discussion started by: RossMc
1 Replies

3. Web Development

Display the contents of a table.

Dear Friends, Am an newbie to this domain. I have a table which is filled with contents which i need to be updated with,so am trying to design a flow which would read the data from the table and mail it to me at regular intervals. I could make out the flow using mailx command but want to... (3 Replies)
Discussion started by: gokulj
3 Replies

4. UNIX for Dummies Questions & Answers

What are the contents of a symbolic link?

Hiii... I wanna know "What are the contents of a symbolic link?"....... From google I dint get a good answer....that's why I posts here...... Thanking you. Krishna (1 Reply)
Discussion started by: krishnampkkm
1 Replies

5. Shell Programming and Scripting

Folder contents getting appended as strings while redirecting file contents to a variable

Hi one of the output of the command is as below # sed -n "/CCM-ResourceHealthCheck:/,/---------/{/CCM-ResourceHealthCheck:/d;/---------/d;p;}" Automation.OutputZ$zoneCounter | sed 's/$/<br>/' Resource List : <br> *************************** 1. row ***************************<br> ... (2 Replies)
Discussion started by: vivek d r
2 Replies

6. Shell Programming and Scripting

Display array contents on a new line

ksh eg arrayname=(1 2 3 4 5) I'm trying to display the individual contents of an array on a new line without using a loop, using one line of code. output 1 2 3 4 5 (3 Replies)
Discussion started by: squrcles
3 Replies

7. UNIX for Advanced & Expert Users

Cannot create a link with the same name

Hi - Our system admin cannot create a link to NAS with one particular name but he can create with other names. What might be the cause? Regards ---------- Post updated at 11:30 AM ---------- Previous update was at 11:29 AM ---------- It says permission denied. (2 Replies)
Discussion started by: w020637
2 Replies

8. UNIX for Dummies Questions & Answers

HTML: Display contents of file using Variable

<tr><td bgcolor=#D7EBAD><b>Instructions :</b></td> <td>`cat temp.txt`</td></tr> Hi Experts, I have an requirement of displaying file contents in HTML mail , for which am using the above approach, Where as the output is kind of not as expected. If there are 5 lines in the file, in the... (4 Replies)
Discussion started by: scott_cog
4 Replies

9. Shell Programming and Scripting

awk to create variables to pass into a bash loop to create a download link

I have created one file that contains all the necessary info in it to create a download link. In each of the lines /results/analysis/output/Home/Auto_user_S5-00580-6-Medexome_67_032/plugin_out/FileExporter_out.67... (8 Replies)
Discussion started by: cmccabe
8 Replies
HOBBIT-ENADIS.CGI(8)					      System Manager's Manual					      HOBBIT-ENADIS.CGI(8)

NAME
hobbit-enadis.cgi - CGI program to enable/disable Xymon tests SYNOPSIS
hobbit-enadis.cgi (invoked via CGI from webserver) DESCRIPTION
hobbit-enadis.cgi is a CGI tool for disabling and enabling hosts and tests monitored by Xymon. You can disable monitoring of a single test, all tests for a host, or multiple hosts - immediately or at a future point in time. hobbit-enadis.cgi runs as a CGI program, invoked by your webserver. It is normally run via a wrapper shell-script in the secured CGI directory for Xymon. hobbit-enadis.cgi is the back-end script for the enable/disable form present on the "info" status-pages. It can also run in "stand-alone" mode, in which case it displays a web form allowing users to select what to enable or disable. OPTIONS
--no-cookies Normally, hobbit-enadis.cgi uses a cookie sent by the browser to initially filter the list of hosts presented. If this is not desired, you can turn off this behaviour by calling bb-ack.cgi with the --no-cookies option. This would normally be placed in the CGI_ENADIS_OPTS setting in hobbitcgi.cfg(5) --env=FILENAME Load the environment from FILENAME before executing the CGI. --area=NAME Load environment variables for a specific area. NB: if used, this option must appear before any --env=FILENAME option. FILES
$BBHOME/web/maint_{header,form,footer} HTML template header BUGS
When using alternate pagesets, hosts will only show up on the Enable/Disable page if this is accessed from the primary page in which they are defined. So if you have hosts on multiple pages, they will only be visible for disabling from their main page which is not what you would expect. SEE ALSO
xymon(7) Xymon Version 4.2.3: 4 Feb 2009 HOBBIT-ENADIS.CGI(8)
All times are GMT -4. The time now is 03:56 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy