How can I set #HOST# variable referenced in the Chart template?

#HOST# and #HOST_PROTOCOL# are being set incorrectly by APEX from CGI variables when I create a chart. I am using APEX 4.1 and Oracle 11g. The get the continual "Loading data..." and then after it times out I get "Error loading file".
Before we changed to a secure http environment, our charts worked. After we changed to the new web layer, the charts do not work. The #HOST# substitution was set to http://correctservername/ and #HOST_PROTOCOL# was set to http. We set PlsqlCGIEnvironmentList REQUEST_PROTOCOL=https in the dads configuration file and now the #HOST# displays https but it also includes the default port number which we do not want (https://correctservername:port/) The charts work without the port. REQUEST_PROTOCOL is not in the cgi list and setting this variable set #HOST_PROTOCOL#. What variable can we set to make #HOST# correct. It seems like #HOST# is being set by #REQUEST_PROTOCOL#'://'||HTTP_HOST||':'||SERVER_PORT||SCRIPT_NAME||'/'. SERVER_NAME could also be used in of HTTP_HOST. I don't know how APEX is setting #HOST#. Does it come from a host alias somewhere in the environment?
I don't want to add a new cgi variable called HOST because HOST sounds so generic and it might interfere with something else running in our environment. Or, I don't want to change the plsql cgi environment variable (such as HTTP_HOST) because many developers may use owa_util.get_cgi_env('HTTP_HOST') to get the current server. If the SERVER_PORT is part of the #HOST# then what could I change it to if it needs to be null. If you leave it blank, then the default SERVER_PORT comes from the CGI variables.
I would rather not create a global variable (hard-coding) and create a new chart template using the global variable or create a before header application process to re-direct url without a port.
Edited by: Donna C-Houston on Oct 10, 2012 1:06 PM

Hi Donna,
changing the CGI environment variables HTTP_HOST, REQUEST_PROTOCOL and SERVER_PORT is the correct way how to resolve this, because it appears that your hiding the web server where you have installed mod_plsql or EPG by a different outside facing web server (also called reverse proxy). That's why APEX gets the host name, protocol and port of the internal web server, but should actually get the values of your reverse proxy web server. Can can fix that by changing the following CGI environment variables.
HTTP_HOST should just contain the domain name (no protocol or port). For example: www.oracle.com
REQUEST_PROTOCOL should contain http or https
SERVER_PORT should be the port for https
I don't want to add a new cgi variable called HOST because HOST sounds so generic and it might interfere with something else running in our environment. Or, I don't want to change the plsql cgi environment variable (such as HTTP_HOST) because many developers may use owa_util.get_cgi_env('HTTP_HOST') to get the current server. If the SERVER_PORT is part of the #HOST# then what could I change it to if it needs to be null. If you leave it blank, then the default SERVER_PORT comes from the CGI variables.The value of HTTP_HOST is wrong anyway and points to your internal web server, but I assume your developers actually want to get the host name of your external web server if they use it to generate absolute URLs. That's why I wouldn't bother and set it to the correct host name.
Regards
Patrick
My Blog: http://www.inside-oracle-apex.com
APEX Plug-Ins: http://apex.oracle.com/plugins
Twitter: http://www.twitter.com/patrickwolf

Similar Messages

  • How can I set a variable number of values in a SQL IN clause?

    Hi,
    How can I set a variable number of values in a SQL IN clause without having to change the text of the SQL statement each time?
    I read the link http://radio.weblogs.com/0118231/2003/06/18.html. as steve wrote.
    SELECT *
    FROM EMP
    WHERE ENAME IN (?)
    But we need the steps not to create type in the system and would there be any other solution if we would like to use variable number of values in a SQL IN clause ?
    We are using JDeveloper 10.1.3.2 with Oracle Database 10.1.3.2
    Thanks
    Raj

    Hi,
    can you please explain why the solution from steve is not the right solution for you.
    regards
    Peter

  • How can I set up two iPhones with the same contact, photos, music etc... but a different sim card and phone number. They will both be my phones, but one will be for use in other countries.

    How can I set up two iPhones with the same contact, photos, music etc... but a different sim card and phone number. They will both be my phones, but one will be for use in other countries.

    Phone A = phone with information you want duplicated
    Phone B = phone that you want to copy from A
    Backup Phone A.
    Wipe Phone B using these instructions. What to do before selling or giving away your iPhone, iPad, or iPod touch - Apple Support
    Phone B should be on the 'Hello' screen. Do not swipe it. Launch iTunes. Plug in Phone B.
    When iTunes asks if you want to set up as new phone or restore from backup, choose restore from backup of Phone A.
    After this setup, any changes to one phone (i.e. adding a contact, downloading an app) will have to be manually duplicated on the second phone, if that is your desire). Making changes to one phone will not affect the other after setup.

  • How can I set up iMessage to ensure the text messages people are sending me arrive both on my computer AND on my iPhone as well?

    How can I set up iMessage to ensure the text messages people are sending me arrive both on my computer AND on my iPhone as well?

    Use the same ID in Settings > Messages > Send & Receive on both devices and have people use that ID. Your iPhone number would be a good choice.

  • How can I set a unique macro for the function keys on my wireless keyboard?

    I'd like to use the F5 key as a quick stroke key for a sentence I use commonly - how can I set that up?

    <http://www.keyboardmaestro.com>

  • How Can I Set Photoshop to Default Open the Most Recent Folder

    Lately, Photoshop CC always opens a default folder-which is several clicks away from the folder I am using. How do I set it to default to the most recent open folder when I click "OPEN" ?

    They would seem to be, but it's possible that they were released separately in the iTunes Store. Some apps are different but named the same (Angry Birds being a case in point). Not having any of those apps I can't say with any certainty. It's definitely not normal for iTunes to keep older versions.
    If you're still on Mac OS X 10.5.6 as your profile indicates, update to 10.5.8 and the latest version of iTunes and see if that makes any difference.
    Regards.

  • When I email myself a picture from my iphone 4s, the email is sent from an email account that I don't have set up as the default account. How can I set it up so that the emails are coming from the default account selected in Mail?

    Under my mail tab, it shows that I have a specific email account set up as a default account. That is the account I would like for me emails to be sent from. But when I actually send out an email such as a picture, it is being sent from one of my different email accounts that is not set up as the default. How can I change this so that future messages will be sent from the default account? Any advice would be appreciated. Thanks!!

    All photo attachments received or sent with the iPhone's Mail app appear inline or viewed in place within the body of the message when viewed with the iPhone's Mail app which is the same with the Mail.app on a Mac. A photo attachment that appears inline or viewed in place does not mean the photo was not sent as a true attachment to the message. A photo attached to a message with the iPhone's Mail app is sent as a true attachment to the message. How an inline or viewed in place attachment appears on the recipient's end depends on the recipient's email client. If the recipient's email client does not support viewing an attached photo inline or viewed in place within the body of the message, the attached file must be manually selected and opened to viewed.
    I am getting the email with the Picture Inline ( not as attachment),The picture is shown distorted , no metter what i do and with what mail client i am using (Gmail\Hotmail\My Enterprise exchange mail), i still get the same behavior.
    With which email client?

  • Can we set a variable used inside the template from the java code.

    Hi everybody,
    I am uploading template,sub template and data xml fle to generate the preview using XDO API's. My main template is calling a sub template so it needs to import the sub template in the main template.since i am uploading my files on a particular server,my subtemplates has been put on different path as specified in the main template.
    so i need to change the subtemplate path dynamically at run time.
    is there any way i can pass this information to my main template at run time.
    one solution could be,my rtf template has a variable 'i' inside it,which is setting the file path to include my subtemplate like this :
    <?xdoxslt:set_variable($_XDOCTX, i ,"import:file:///c:/Temp/htmlmarkup.xsl")?>
    <?xdoxslt:get_variable($_XDOCTX, i )?>
    now is there any way i can set this variable at run time from my external java code.?
    Thanks,
    Anuradha

    Thanks for the response.
    but i still am looking for the solution.
    if both my template and subtemplate are in the same directory then atleast
    <?import:file:../htmlmarkup.xsl?> should work.
    but its not working...i m getting following error:
    FOProcessor setData: C:\subtemplates\projects.xml
    FOProcessor setLocale: en-us
    java.lang.reflect.InvocationTargetException
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at oracle.apps.xdo.common.xml.XSLT10gR1.invokeNewXSLStylesheet(XSLT10gR1.java:514)
         at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:192)
         at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:156)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:916)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:869)
         at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:204)
         at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1535)
         at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:925)
         at RTF2PDF.runRTFto(RTF2PDF.java:590)
         at RTF2PDF.runXDO(RTF2PDF.java:443)
         at RTF2PDF.main(RTF2PDF.java:237)
    Caused by: java.io.FileNotFoundException: C:\Documents and Settings\fusion\htmlmarkup.xsl (The system cannot find the file specified)
         at oracle.xdo.parser.v2.XSLProcessor.reportException(XSLProcessor.java:782)
         at oracle.xdo.parser.v2.XSLProcessor.newXSLStylesheet(XSLProcessor.java:564)
         ... 15 more
    please suggest me what to do..

  • How can I set a default zoom for the browser (freeze it)?

    Hello, there's an option of using the Ctrl + + to zoom the Web page, but it reverts to the Firefox default zoom in the midst which is very annoying. Generally, I'd like to be able to set a certain default zoom level and then only if needed use the CTRL +/- zoom in and out options. So my optimal zoom level is used for all my browsing unless I change it.

    I have listed 2 add-ons below for you to consider. I have not used NoSquint, but I use and rely on Default FullZoom Level.
    *You can set a default zoom level in DFZL Options
    *You can use the mouse scroll wheel on the Add-on Bar DFZL icon to increase or decrease the zoom or click the icon and choose from the available zoom percentages.
    *In NoSquint, it says it saves the zoom level by web site/page.
    *'''''Default FullZoom Level''''': https://addons.mozilla.org/en-US/firefox/addon/default-fullzoom-level/
    *'''''NoSquint''''': https://addons.mozilla.org/en-US/firefox/addon/nosquint/
    **More info on NoSquint: http://urandom.ca/nosquint/
    You can also set a "Minimum Font Size" in Firefox Options > Content > Fonts & Colors Advanced".
    *See --> [https://support.mozilla.com/en-US/kb/Options%20window%20-%20Content%20panel#w_fonts-colors Options window-Content panel-Fonts & Colors]
    '''If this reply solves your problem, please click "Solved It" next to this reply when <u>signed-in</u> to the forum.'''
    Not related to your question, but...
    You may need to update some plug-ins. Check your plug-ins and update as necessary:
    *Plug-in check: https://www-trunk.stage.mozilla.com/en-US/plugincheck/
    *Adobe Shockwave for Director Netscape plug-in: [https://support.mozilla.com/en-US/kb/Using%20the%20Shockwave%20plugin%20with%20Firefox#w_installing-shockwave Installing ('''''or Updating''''') the Shockwave plugin with Firefox]
    *Adobe PDF Plug-In For Firefox and Netscape: [https://support.mozilla.com/en-US/kb/Using%20the%20Adobe%20Reader%20plugin%20with%20Firefox#w_installing-and-updating-adobe-reader Installing/Updating Adobe Reader in Firefox]
    *Shockwave Flash (Adobe Flash or Flash): [https://support.mozilla.com/en-US/kb/Managing%20the%20Flash%20plugin#w_updating-flash Updating Flash in Firefox]
    *Next Generation Java Plug-in for Mozilla browsers: [https://support.mozilla.com/en-US/kb/Using%20the%20Java%20plugin%20with%20Firefox#w_installing-or-updating-java Installing or Updating Java in Firefox]

  • How can I set 50 variables with the values that are inside an array?

    Hello,
    I have and array of numbers and an array of strings ( the name of the variables) These values are acquired every time from hardware.
    Now I created a graphical interface with 53 of these variables, and I need to create a link to update them with the correct value.
    Thanks
    Dario
    Attachments:
    Example_insert_53_values_in_53_varialbes.vi ‏23 KB

    Dario,
    you have posted your question to the Profibus forum. As your question is not directly related to Profibus, but to LabVIEW programming, your better should post it to the LabVIEW forum.
    Thanks
    Jochen

  • How can I set up an email where the mail account is totally different to the email address?

    The email account (and password related to it) is in the form "xxxxxx.ndonet.com." The email address is "xxxxxx.ndirect.co.uk." There don't seem to be many email clients that allow this and at present I am having to use Pegasus. I have tried manual configuration in Thunderbird but without success. Is it possible?
    Thanks in advance.

    Thanks to you both for your suggestions. It is very helpful.
    I have solved one problem but have one remaining. I can now send mails having configured TB with the ISP's pop3.hosts.co.uk and port 995. This is working fine. Sending is still a problem. As I am currently in France I cannot test smtp.hosts.co.uk (587) directly. I usually use smtp.orange.fr. Under Pegasus this is set using Server TCP/IP port = 25 and Timeout = 15 seconds, which works every time. When I try TB with either 25 or 587, I get an error "login to stmp.orange.fr failed" and a further message "for unknown reason" although sometimes it reports "authentication failed".
    I am a bit out of my depth here and would be grateful for further suggestions. Thanks.

  • How can I set trace on?  In the parameter config file

    I tried this trace traceoopts="trace_all" it didn't work.
    can you tell me how to set trace on in the configuration parameter file?

    For Inprocess server the conf file name is rep_<hostname>.conf
    For standalone server the conf file name is <servername.conf>
    For Builder conf file name is rwbuilder.conf
    Uncomment the trace element and restart server/builder. The logs should be in $OH\reports\logs\
    Pls make sure you are modifying conf file of appropriate executable
    [    All Docs for all versions    ]
    http://otn.oracle.com/documentation/reports.html
    [     Publishing reports to web  - 10G  ]
    http://download.oracle.com/docs/html/B10314_01/toc.htm (html)
    http://download.oracle.com/docs/pdf/B10314_01.pdf (pdf)
    [   Building reports  - 10G ]
    http://download.oracle.com/docs/pdf/B10602_01.pdf (pdf)
    http://download.oracle.com/docs/html/B10602_01/toc.htm (html)
    [   Forms Reports Integration whitepaper  9i ]
    http://otn.oracle.com/products/forms/pdf/frm9isrw9i.pdf

  • How can i set up different IDs under the same account so that each of my children can use itunes cards but not access or share each others

    i have 3 ipods one for each child.. i need to set it up so that each have access to my account but individually so that they cannot use each others itunes money

    Hi Felicia,
    Are you wanting them to have access to your account so they can purchase items using your credit card? Or do you want them "sharing" your account for some other reason?
    GB

  • How can one set a default location for the pictures on the hard drive?

    Since Windows normally places the pictures on a typical drive as "My Pictures" about four or five levels down from the root, any effort to import picture files into Lightroom requires multiple clicks to drill down to the "My Pictures" then (for example) year, month, date, etc.
    Can I define a location as the default starting point to find the pictures?  I don't see how to put that into presets. Or can a key shortcut be created to go straight to c:/users/name/mypictures/2013/April15 etc?
    Steve Board

    dj is right. Any Folder can be a picture folder.
    Create a root level folder and add it to your Pictures Library in Windows.  It will show up with all the scattered pictures from other programs. It can even be a different dirve if you like.  You  can even specify one to be the default save location for pictures in this dialog.
    Navigate to Pictures in your Libraries in Windows Explorer Right Click and select Properties.
    Message was edited by: Rikk Flohr forgot the instructions...

  • HT202157 How can I set time and date in the Apple TV???  This step doesn't let me go on with installing itunes!

    The area is set for San Juan, PR, but it doesn't recognize the date and time.

    This indicates a network issue.  Ensure DNS settings are set to Automatic and the regional settings are correct.

Maybe you are looking for

  • Storing an object to be read in by a shell command

    Hm, sorry if i got the subject wrong bcos i seriously duno how to phrase it.. I got a java application with a GUI as a configuration manager i got a shell command running in the back ground the shell will read in my java class... (which will contain

  • System-Crash after KDE4 upgrade

    Hello, maybe anybody can help me mount /mnt/wd2tbhdd/ mount: unknown filesystem type 'ext3' pacman -S kernel26 warning: linux-3.2.2-1 is up to date -- reinstalling resolving dependencies... looking for inter-conflicts... Targets (1): linux-3.2.2-1 To

  • How to Handle Multi Value  Indexes

    Hi all, i'm a newbye and i've a class attribute which is a String Array, and i want to create a secondary index on this attibute. I'm wondering which is the best solution to achieve this.

  • Procedure with Cursor

    I have the following code: CREATE OR REPLACE PROCEDURE RENTALPAYMENTS( p_PROPERTY_DETAIL_ID LMR_PROPERTY_DETAILS.LMR_PROPERTY_DETAIL_ID%TYPE ) IS CURSOR property_detail_cur IS SELECT RENT, BOND, START_DATE, LEASE_PERIOD, PAYMENT_INTERVAL, PROP_PROPER

  • Cisco Catalyst 6500 Supervisor Engine 2T Baseboard

    Morning Guys i have just bought a Cisco 6506-E Chassis, it came out with only the SUP2T Engine on slot 5, i have already stacked 3 switches (3750-X) as my core, i want to replace them with the chassis the problem now is my company doesn't have money