|
So far I have found PayPal Sample[^], There's a lot of code written for each step. At last you will find a logic on redirecting back to your webpage after completing transaction. I think There's same idea as in page for all transactional websites.
Regards,
Hiren.
Microsoft Dynamics CRM
"A SQL query goes into a bar, walks up to two tables and asks, "Can I join you?", "yes naturally""
|
|
|
|
|
|
An observation and a bit of a question:
I've got a DropDownList on a web page (C#, but that doesn't matter)
It is set to AutoPostback & ViewState is turned on.
IF there are duplicate Values in the dropdown (not the Text, just the Values), it will NOT maintain its selected index, but rather return from the postback with the first of the duplicate Values selected.
Example: This is what it looks like after a postback from selecting "CHAPLAIN"
<option value="TBD">ACQUIS & MATERIEL MGMT</option>
<option value="xxxxxxHolliT">AMBULATORY CARE</option>
<option value="xxxxxxBrownJ">ANESTHESIOLOGY</option>
<option selected="selected" value="TBD">ASSOC DIR/NURSING SVC</option>
<option value="TBD">ASST DIR/OPERATIONS</option>
<option value="xxxxxxWackeR1">BLIND REHABILITATION SVC</option>
<option value="TBD">CHAPLAIN</option>
<option value="TBD">CHIEF OF STAFF</option>
See what I mean?
Is this a known behavior? Or a bug?
|
|
|
|
|
AFAIK its know behavior. Selected status is stored based on the value not the ordinal, hence the SelectedValue property. With duplicate values it just picks the first one as you can see. It just doesn't make sense to have the same values for multiple items.
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
Mark Nischalke wrote: It just doesn't make sense to have the same values for multiple items.
Sure it does, in circumstances a DropDownList is apparently no good for.
For instance, a list of Names, with their gender in the Value.
It's the other way around that wouldn't make sense. A list of 47 Bobs...you wouldn't know which one to pick even if their Values were different.
But Bob Smith, Bob Dobbs, Bob1 and Bob2 could all be male in Value.
No matter. I found a diffent way of doing what I was doing.
|
|
|
|
|
It simply means you are using the value field for something that it isn't intended to be. The value field meant in theory to be used like the key in a hashlist or the primary key in a table. If you have another value that you'll need, you can always add a custom attribute to each ListItem, but at the end of the day a single-selectable item control should have unique ids for each item...
I wasn't, now I am, then I won't be anymore.
|
|
|
|
|
GenJerDan wrote: For instance, a list of Names, with their gender in the Value.
Then I wouldn't use a DropDownList
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
i want to submit form in asp.net
I think that form object can be stored in formS variable by using "var formS = document.getElementById("form2")"
but i don't know how can i submit.
/////////////////////////////////////////////////////
function show_win(userName) {
var formS = document.getElementById("form2");
formS.action(); //<-- Here is error.
}
<asp:textbox id="TextBox1" runat="server">
<asp:button id="Button1" runat="server" text="Button" onclientclick="show_win('admin')">
|
|
|
|
|
formS.submit() should do the trick for you!
Cheers!
|
|
|
|
|
Hi,
I want to ask where is the best place to save the web application version? because i want to show the version on my default page but I thought if there is a specific place to save other than Global file?
Thanks
|
|
|
|
|
Probably in web.cofig as It's not accessible from outside.
Regards,
Hiren.
Microsoft Dynamics CRM
"The difference between the impossible and the possible lies in a person's determination" - Tommy Lasorda
|
|
|
|
|
As Hiren suggested, you can save it in web.config . I have several projects (small as well big) saving it in config file.
|
|
|
|
|
Place it in web.config in app settings section. Then you will be able to read it easily in code like
ConfigurationManager.AppSettings["YourApplicationName:VersionInfo"]
I Web Development Free Lancer
Share your experience with others
Check my Blog...
|
|
|
|
|
If I have the following url currenty on my page?
http://www.JassimRahma.com/url/abc/database.aspx?id=345&cur=654
how can I determine the page name from my code to get:
database
Thanks
|
|
|
|
|
string sPath = System.Web.HttpContext.Current.Request.Url.AbsolutePath;
System.IO.FileInfo oInfo = new System.IO.FileInfo(sPath);
string sRet = oInfo.Name;
return sRet;
Regards,
Hiren.
Microsoft Dynamics CRM
"The difference between the impossible and the possible lies in a person's determination" - Tommy Lasorda
|
|
|
|
|
Hi,
I am developing a simple online DBMS to browse my database online.... the main concern for me is to clear everything from the PC when the user disconnect so no body can go and click (Back) on the browser and see the pages if the user forgot to close it.. what I have done so far is :
Session.RemoveAll();
Response.Clear();
Response.Redirect("Default.aspx");
I am sure this is not enough.. am I right? so what else I should include there?
|
|
|
|
|
Q. What if the user hits CTRL+A, CTRL+C and then CTRL+V in notepad and forgets to close that?
A. It is there own stupid fault if others see the data
Where and when is your example code being called?
Life goes very fast. Tomorrow, today is already yesterday.
|
|
|
|
|
musefan wrote: Where and when is your example code being called?
What is wrong with that question that gets a vote of 1?
Life goes very fast. Tomorrow, today is already yesterday.
|
|
|
|
|
You need to clear the cache too. Refer this[^]
thatraja |Chennai|India|
Brainbench certifications Down-votes are like kid's kisses don't reject it Do what you want quickly because the Doomsday on 2012
|
|
|
|
|
You should really abandon the session rather than just remove all of the contents. The response.clear and redirect don't do anything to get rid of the history. You need to be looking more at the cache.
If you do everything in update panels or with other ajax methods, then the back button won't do much.
|
|
|
|
|
in UPS site there is a login button. when user click on a login button then a popup appear. so i want to design a div or iframe having save look & feel. the site url is http://www.ups.com[^].
please someone go there and help me to design same look and feel div.
thanks
tbhattacharjee
|
|
|
|
|
hi guys,
my site will be using ajax methods and i don't want clientside to view my ajax(js) code when they view
the source code of my site..
Does anyone know how i can hide my ajax files so that they are not viewable on clientside?
For instance you can import a css file using the @Import command..I tried something similar in javascript
with below code:
var script = document.createElement('script');
script.src = '../ajax/login/login.js';
script.type = 'text/javascript';
document.getElementsByTagName('head').item(0).appendChild(script);
with the above, none of my methods in the login.js file are loading...
Please help me.
|
|
|
|
|
By definition, a client side file (which your ajxx/javascript files are) are sent to the client. In plain text. So no matter what you do, you cannot stop a determined user from viewing them. You can minify and obfuscate them, but while that may deter an inexperienced user, it won't stop anyone that knows what they are doing.
But the question is: why do you want to? Never, ever, put sensitive data in a javascript file.
|
|
|
|
|
Try using some encryption or obfuscation method to secure your client side javascript.
I Web Development Free Lancer
Share your experience with others
Check my Blog...
|
|
|
|
|
In general, you can't hide something from the client if you need the client to use it. My suggestion would be to convert all your js files to aspx files and set the content type. Have them do a referer check and set the caching options to not cache. It won't be good for performance and it won't stop a seriously determined person, but it should be a pretty big speed bump to most people.
|
|
|
|