Javascript and vbscript on same page?
I an editing a customers site which had some old server side javascript on the page.
I need to use vbscript on the page now as the page is being upgraded to aspx instead of asp.
The question is, do I need to upgrade all the existing server side javascript on the page to vbscript or can the two co-exist side by side?
Thank you
Terry
terryfoster wrote:
I wish I could, he left when the tea stopped flowing!
Hi
I'm not surprised they left.
aspx pages are Microsoft's .net pages which is completely different to asp. Using both on the same page will depend on your server set-up, but javascript is not a language you can use for aspx, and I would not recommend mixing them except for the most basic usage.
Your choices for aspx are - C#, vbscript, C++, Java++,, there are a few others but I have never heard of anyone using them.
You can use javascript for your client-side, (browser) scripting language though.
PZ
Similar Messages
-
How to print Header and footer in same page
Hi All,
I am using Oracle Report 10g. How can I add header and footer on same page as my body? Right now when a generate a pdf file, it is printing individual pages instead of 1 one page. Please help me.
RegardsHI
First of all,
Unless otherwise you selected some option like page break after/before - both body and header/footer will print on same page in report, so in pdf as well.
If you have difference on report and PDF that you should look into your setup.
If you want more help, please be particular on your issue
james. wrote:
Hi All,
I am using Oracle Report 10g. How can I add header and footer on same page as my body? Right now when a generate a pdf file, it is printing individual pages instead of 1 one page. Please help me.
Regards -
Combining Flashvideo and javascript nav-menu in same page?
Hi,
I'd be very greatful if I could get some help with the
following.
I have a page where I want to to insert a flash video. Only
problem is that I have built my navigation menu with a plugin from
PVII (PopMenuMagic-plugin) and it uses a bit of javascript.
So there is a mention of the menu's javascript in the
<head> and also in the <body onload=""> tag.
And this seems to collide with the mention of javascript that
Dreamweaver inserts relating to Flashvideo in the <head> tag
as well as it has its own <body onload=""> tag.
I don't know javascript (which is why I got the plugin in the
first place) so I don't know how to combine the flash video and the
navigation menu on the same page.
1) I don't know if there is a collision in the <head>
area between the javascript statements.
2) I don't know how to combine the 2 <body onload="">
arguments into a single argument.
A page with the working flash video can be seen here:
And a page with the navigation menu can be seen here:
Does anyone have an idea of how to resolve this?
I was thinking perhaps I could put the video in an iFrame as
a workaround but it would be nice to do it correctly without
iFrames.
Thanks!Hello ,
I think what you need in Windows Phone 8 for the menu buttons is the Pivot Control(see
[1]).
You can find the code for the LongListSelector at
[2].
[1]
https://msdn.microsoft.com/en-us/library/windows/apps/hh202890(v=vs.105).aspx
[2]
https://msdn.microsoft.com/en-us/library/windows/apps/jj244365%28v=vs.105%29.aspx
Regards,
Bo Liu
Developer-Hotline for MSDN Online Germany
Disclaimer:
Please take into consideration, that further inquiries cannot or will be answered with delay.
For further information please contact us per telephone through the MSDN-Entwickler-Hotline:
http://www.msdn-online.de/Hotline
For this post by the MSDN-Entwickler-Hotline the following terms and conditions
apply: Trademarks,
Privacy
as well as the separate
terms of use for the MSDN-Entwickler-Hotline . -
Use a Jump Menu to Make Selection and stay on same page.
I have a form that you select a ID from a drop down list
click submit, and then are redirected back to the same page with
the results of a query based on the selection from the drop down
list. I want to change this so the user doesn't have to click
submit... I want my drop down list to act as a jump menu. How do I
get my dropdown list to act like a jump menu, which essentially
submits the form, and posts the results below?2 ways, both use javascript (you can't do it with just cf):
1) add an onChange attribute to your select with
'this.form.submit()' as
value. this will submit the form, refresh the page and show
your results
- just as if user clicked your 'submit' button. be careful,
though, if
you are checking for existence of the submit button in your
action page
- it won;t be there since it has not been clicked.
2) you can also employ some ajax features to submit your form
asynchronously, 'behind the scenes', and show results without
refreshing
the page. CF8 has built-in ajax js functions and tags to do
it,
otherwise look into ajaxcfc by rob gonda or jQuery or other
js framework
that has these features.
hth
Azadi Saryev
Sabai-dee.com
http://www.sabai-dee.com/ -
Using VO as form and table on same page
Hi,
We are facing some issues while using same view object on one page. The view object is dropped as input form and as table on same page. There are few fields in the input form that have autosubmit property set to true. Now while entering the data into form, after clicking any autosubmit field, if we refresh the page, then new row gets created in table with value of the auto submit field. This is in cache only and not created in DB. We tried by exposing two instances of same view object in application module but still same issue. Finally we created two view object, one which is EO based and another ready only through query. Its working fine now. But is there any other possible solution, without creating two view objects?
Jdev: 11.1.1.6.
ThanksHey Ami,
I've tried understanding your problem but i'm not sure if i could.
The problem is that you can insert via the form but it doesn't update the table ?
Is that it ?
Regards,
Frederico. -
How to refresh and redirect into same page after deleting a file
Hi John,
One more help I need. I implemented the brows and download file functionality in my application successfully. And I am interested to implement delete also like download. If user will click on download three options will come open, save, cancel in case of download. But like download I want to put delete link which will delete the corresponding file.
I written the procedure in same fashion as download and compiled in my schema.
The code is here:
CREATE OR REPLACE PROCEDURE download_my_file_temp_delete (p_file IN NUMBER)
AS
BEGIN
DELETE FROM file_subjects_temp
WHERE ID = p_file;
END download_my_file_temp_delete;
And in
Home>Application Builder>Application ID>my_page > Report Attributes>Column Attributes
There I am entering
Link text : Delete
Target : URL
URL : #OWNER#.download_my_file_temp_delete?p_file=#Delete#
Where download_my_file_temp_delete is a procedure for deleting the file corresponding to ID .
Here id alias is DELETE so I am passing #DELETE#.
If I am click delete corresponding to any file its opening a blank page I seen URL is like
http://abcd.com:portno/pls/workspace/owner.download_my_file_temp_delete?p_file=4031625747435433
if I am clicking back and refreshing then getting file is deleted successfully.
That means procedure is working but I want that after clicking on delete link corresponding to any file same page should appear with refresh then my problem will solved.
Can u suggest me any approach.
Thanks && Regards,
Ravi[This is not John, hope that's ok!]
This kind of thing is best done by rendering checkboxes next to each file in your report region;using apex_item.checkbox(1,file_id) and providing a Delete button that would fire a after-submit process that does
for i in 1..htmldb_application.g_f01.count
loop
download_my_file_temp_delete(htmldb_application.g_f01(i));
end loop;[And of course a same-page branch on the page] -
Select Query and Recordset on same page
I have been workig with Coldfusion for a while now. Where I work there is a need for web pages to extract data from data sources. I have been successful at doing this. Typically I use a form that selects multiple criteria, which when submitted loads a target/action page that displays records that are filtered based on the SQL statement contained on that action page. What I do is to conditionally check if criteria is passed using cfif. And if a field parameter is indeed passed it becomes part of the cfquery. This works out well - especially for reporting.
But now I am seeing more and more a need to accomplish the same process - but on a single cfm page. So the page I seek will have both the form (select) and the recordset results on the same page.
In this exercise I will be caching results od a query and having several queries to further refine what I seek (QOQ). What I am seeking is the best practice to follow, I was thinking that using an iframe on the page would be and adequate solution whereby the query would pass the criteria and its form action would pass the variable(s) to the action page, which would be the source of the iframe. But I am not certain that this is a best proctice. Nor have I had great success at getting the pages to work in concert.
Any advice that you can lend would be appreciated.I ideally start by reducing the 2-page functionality - of form page and action page - to just one. It goes like this:
<cfset isValidationPassed = false>
<cfif isDefined("form.someVar")>
<!--- Do validation. Validated form implies isValidationPassed is true --->
</cfif>
<cfif isValidationPassed>
<!--- Do action page stuff --->
<cfelseif NOT isDefined("form.someVar") OR NOT isValidationPassed>
<!--- Display the form. --->
<!--- If form had been submitted, inform user which validation failed, and what to correct. Display the form. --->
<cfoutput><form method="post" action="#CGI.SCRIPT_NAME#"></cfoutput>
</form>
</cfif>
The idea is then to pile on the complexity, layer by layer. -
8.0.2 Insert and Update on same page?
With 8.0.2 is it possible to have an update and insert on the
same page?On Fri, 19 Jan 2007 08:34:35 -0600, Lee
<[email protected]>
wrote:
>Did you have to tweak the code to get them to work
together (changing
>function names) or did they work automatically?
>
>Perhaps it's just what I am trying to do with the page. I
have two forms
>and depending on which they need, either the update is
used or the
>insert is used.
>
>Does this still sound like it should work?
Reply in the App Dev forum.
Steve
steve at flyingtigerwebdesign dot com -
I used the wizard to create a report and form on a table. When the user hits the edit link on the report, it brings up the form (so they can edit) on a new page. Instead of this, I want the form to show on the same page as the report. What is the best way to do this? Should I create 2 regions on the same page (1 for the report and 1 for the form)?
Bob,
take a look at
Re: How to get a form to appear on the same page when a button is clicked?
at the end you can login to a (my) workspace to see how it's done.
Leo -
Problem with Javascript and opening a new page
Hi,
I'm developping a website with Java Server Faces.
I've a problem with JavaScript.
I have a table, and each row of that table, has a button, to display more information about that specific row. I want to display this information in a new window. For this I want to use JavaScript.
The new window, of course, needs some information of the other window, to show the right data.
The first time I click the 'more-information-button', it works perfectly, but from than on, he keeps showing the same information...
Here is my jsp-page of the first page (the one with the table):
<?xml version="1.0" encoding="UTF-8"?>
<jsp:root version="1.2" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" xmlns:jsp="http://java.sun.com/JSP/Page">
<jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
<f:view>
<f:loadBundle basename="languages.MessageBundle" var="bundle"/>
<html>
<head>
<meta content="no-cache" http-equiv="Cache-Control"/>
<meta content="no-cache" http-equiv="Pragma"/>
<title>- UCV-Period -</title>
<link href="resources/stylesheet.css" rel="stylesheet" type="text/css"/>
</head>
<body style="-rave-layout: grid">
<h:dataTable binding="#{UcvPeriod.dataTable1}" headerClass="list-header" id="dataTable1" rowClasses="list-row-even,list-row-odd" rows="5"
style="left: 24px; top: 168px; position: absolute" value="#{UcvPeriod.dataTable1Model}" var="currentRow">
<h:column binding="#{UcvPeriod.column1}" id="column1">
<h:outputText binding="#{UcvPeriod.outputUcvPeriod}" id="outputUcvPeriod" value="#{currentRow['UCVPERIOD']}"/>
<f:facet name="header">
<h:outputText binding="#{UcvPeriod.outputText2}" id="outputText2" value="#{bundle.ucvPeriod_columnHeader_ucvPeriod}"/>
</f:facet>
</h:column>
<h:column binding="#{UcvPeriod.column11}" id="column11">
<h:commandButton action="#{UcvPeriod.btnDetails_action}" binding="#{UcvPeriod.btnDetails}" id="btnDetails" value="+" onclick="window.open('Details.jsp')"/>
<f:facet name="header">
<h:outputText binding="#{UcvPeriod.outputText21}" id="outputText21" value=""/>
</f:facet>
</h:column>
</h:dataTable>
</h:form>
</body>
</html>
</f:view>
</jsp:root>Here is my action, when someone clicks on the 'more-information-button':
public String bthnDetails_action() {
Object s = outputUcvPeriod.getValue();
BigDecimal ucvPeriod = (BigDecimal)outputUcvPeriod.getValue();
this.getSessionBean().setUcvPeriod(new Integer(ucvPeriod.intValue());
return "detail_ucvperiod";
}Here is my constructor of the Detailspage.
public Details() {
this.txtUcvPeriod.setValue(this.getSessionBean().getUcvPeriod());
}Here is the navigation part for this part of my faces-config.xml .
<navigation-rule>
<from-view-id>/UcvPeriod.jsp</from-view-id>
<navigation-case>
<from-outcome>detail_ucvperiod</from-outcome>
<to-view-id>/UcvPeriod.jsp</to-view-id>
</navigation-case>
</navigation-rule>Thx a lot....
AnnekeSee the tutorial "Sharing Data Between Two Pages" at http://devservices.sun.com/premium/jscreator/standard/learning/tutorials/data_sharing_twopages.html and the FAQ "How can I pass data between pages without creating SessionBean variables in Creator?" at http://devservices.sun.com/premium/jscreator/standard/reference/faqs/technical/javasource/passing_data.html. Since you can open a new window when your button is clicked, the tutorial and FAQ will explain ways to pass your data to the new window.
-
Hyperlinks (target="_blank") and buttons on same page problem.
Another interesting problem.
I have a hyperlink that is set to open in a new window (target='_blank') and execute the 'hyperlink1_action' on the server.
The framework executes the javascript function 'hyperlink_submit' (in the formElements.js library) when a hyperlink is clicked. This function sets the 'target' property on the form and also creates a hidden field that identifies the hyperlink that was clicked.
This works fine and a new window open up with the required data.
However, now if I click a BUTTON on the ORIGINAL page, a NEW WINDOW pops up and the WRONG DATA is displayed due to the form target setting and hidden field that were created by the 'hyperlink_submit' function called prevously - ie. the changes to the form made by the 'hyperlink_submit' function are NOT rolledback/overwritten when the button is clicked. How annoying!!!
Am I doing something completely wrong or what?
Anyway, I feel better now. Have a nice day!
Message was edited by:
thepigs2
OK. In the absence of any replies, I've come up with this superhack that I put at the end of the page which fixes the form...
<f:verbatim>
<script>
var f = document.getElementById('form1');
f.oldsubmit = f.submit;
f.submit=function() { setTimeout(function(){resetForm(f);},250);return f.oldsubmit(); }
function resetForm(f)
f.target='';
for( var i=f.childNodes.length-1; i >=0; i-- ){
var n = f.childNodes;
if (n && n.name)
if (n.name.indexOf('_submittedField')>-1)
f.removeChild(n);
</script>
</f:verbatim>Guillaume,
The built-in tabular form feature only supports one tabular form on each page. You'll have to put the two forms on separate pages. Or use simple reports as the detail reports with edit links to an edit form page.
Regards,
Marc -
How to get the value from a JavaScript and send the same to Java file?
Hi.
How to get the value from a JavaScript (this JS is called when an action invoked) and send the value from the JS to a Java file?
Thanks and regards,
Leslie VYes, I am trying with web application.
In the below code, a variable 'message' carries the needed info. I would like to send this 'message' variable with the 'request'.
How to send this 'message' with and to the 'request'?
Thanks for the help :-)
The actual JS code is:
function productdeselection()
var i=0;
var j=0;
var deselectedproduct = new Array(5);
var message = "Are you sure to delete Product ";
mvi=document.forms[0].MVI;
mei=document.forms[0].MEI;
lpi=document.forms[0].LPI;
if(null != mvi)
++i;
if(null != mei )
++i;
if(null != lpi)
++i;
if(null != mvi && mvi.checked)
deselectedproduct[++j]="MVI?";
if(null != mei && mei.checked)
deselectedproduct[++j]="GAP?";
if(null != lpi && lpi.checked)
deselectedproduct[++j]="LPI?";
if( 0!=j)
if(i!=j)
for (x=0; x<deselectedproduct.length; x++)
if(null != deselectedproduct[x])
message =message+ "-" +deselectedproduct[x];
alert(message);
else
//alert(" You cannot remove all products!");
return false;
return true;
} -
Opening Numbers and getting the same page size and location each time
Can someone help me with something which is pretty basic, please?
When I open a Numbers spreadsheet which I use frequently, each time it opens as a tiny box and always has to be resized and repositioned onscreen before I can start work.
I figure there must be something I can do to have it open in the same screen position and the same size each time, but what?Hi Norman,
Your tags show OS X Mavericks 10.9. The latest version of Mavericks is 10.9.2
Are using Numbers 3.0 ? The lates version of Numbers is 3.1 and it does save the zoom.
Maybe this will help, but it does not work in Numbers 3.0
Numbers > Preferences > General > Default Zoom > 100% (or whatever % you want).
And Save your document before closing to retain the zoom and position.
The Numbers *window* size can not (yet) be saved, but the zoom and the position within a sheet can be saved in Numbers 3.1
Regards,
Ian. -
Include custom javascript and css in uix page
Hello
I got a UIX page based on the pageLayout template and i wanted to include some custom things (css, js) inside the resulting html header like this:
<document>
<metaContainer>
<!-- Set the page title -->
<head title="mypage"/>
<html:link rel="stylesheet" type="text/css" href="http://someotherserver.com/generateStyle?pCSSType=loc"/>
<html:link rel="stylesheet" type="text/css" href="http://someotherserver.com/generateStyle?pCSSType=sys"/>
<script source="customScript.js"><contents><!-- --></contents></script>
</metaContainer>
<contents>
<body>
Unfortunatly only ONE thing from within "metaContainer" gets included in the final html file. Is there a way to include everything from within "metacontainer"?
Thanks for your help,
Philipp StecherI think metacontainer is a named child, and like all named children it can only have one node.
Does this work?
<document>
<metaContainer>
<!-- Set the page title -->
<head title="mypage">
<contents>
<html:link rel="stylesheet" type="text/css" href="http://someotherserver.com/generateStyle?pCSSType=loc"/>
<html:link rel="stylesheet" type="text/css" href="http://someotherserver.com/generateStyle?pCSSType=sys"/>
<script source="customScript.js"><contents><!-- --></contents></script>
</contents>
</head>
</metaContainer> -
JAVASCRIPT AND JSF PROBLEM REFRESHING PAGE PROBLEM
Hello everyone, I am currently using visual JSF and javascript to to disable a fileupload component when a radio button is clicked. I don't have any problems getting it to work if I need to disable a button, a textfield or other visual JSF components. For some reason, i can't disable the fileupload component and I get this error when the JAVASCRIPT is called:
Error: document.getElementById("form1:fileUpload1").refresh is not a function
Source File: http://localhost:8080/TestSingleEvent/theme/com/sun/webui/jsf/suntheme4_2-080320/javascript/webui.js
Line: 22
My javascript code is the following:
document.getElementById("form1:fileUpload1").refresh("form1:radioButton1");return false;
I would appreciate some help here. Why is it that when I replace the fileUpload with i.e a textfield i don't get errors..
Is it something to do with the webui.js ?
Many thanks.There is no such thing as refresh() in the [DOM element|http://developer.mozilla.org/en/DOM/element]. How did you come to this? Did you a wild guess in the around without reading the docs? Don't do that.
What exactly do you want to achieve? Reset its value? Then set the 'value' property to null. Disable the element? Then set the 'disabled' property to true.
I've been helpful enough with this offtopic question. If you still stucks, please continue at a Javascript oriented forum. There's one at under each webdeveloper.com.
Maybe you are looking for
-
Windows 8 user getting error 2343 when trying to uninstall iCloud
I had to uninstall iTunes & all associated files due to a sync issue with a new device. Anyway. I uninstalled iCloud 3.1 with no problems. I then tried to uninstall v3.0.7! I get error 2343. I have cleared the registry, updated all my windows servic
-
I am able to print but I am unable to scan. I am using a Mac OS X 10.8.5.
-
Ignore records in select statment
I am beginning to forget sql.I know it is easy but just not able to get there. I have table MY_TABLE name postal_code error I want to get all records except those records where postal_code is empty and error is 10. please help.
-
How do i trim a music score?
I am trying to clip out 3 seconds from a music score in PE. So far, no success. If I trim or clip out a section, it seems to ignore the edit and simply play from the beginning. I am missing something? If not, is there any way to export to music and e
-
Final cut pro 6.0.5 crash - won't launch
hey everyone, i'm new to this forum, been looking through the posts to see if i could find some answers but i haven't had any luck. i recently did a software update on my machine, noticed there was a pro application support for final cut studio. i we