Hi everyone,
I'm looking for a way with one statement to change the value of a tinyint field (named 'is_archive') in a table to either:
zero if its current value is one
OR
one if its current value is zero
Is there a way to do this without having to first query the table to get the current...
I've figured it out...
opener is not defined for modalDialog, instead, I found what I needed nested in the window.dialogArguments object.
Thanks for your help Dan as what you posted will work in every other situation except for this special case with IE where showModalDialog() is used in place...
Ok I think I've identified the problem.
The HTML editor I'm using (FCKeditor) uses showModalDialog() to open the popup if it detects IE and after trying different variations of the window.opener syntax discussed above, it (opener) seems to be undefined every time in IE.
So, does anyone know if...
Thanks Dan,
I was able to get the URL of the page I needed using the following:alert(parent.opener.parent.location);
However this worked in Firefox but not IE..
Is there something syntactically wrong/non-standard with the above code, or at least another way to write it so that IE would...
I'm trying to modify a js based html editor and what I need to do seems quite simple but I'm having trouble.
The editor loads in an iFrame, and the iFrame launches a popup window. Within the popup window, I need to determine the URL of the page that contains the iFrame.
I've tried...
Interesting .. I ran another test on a machine running CF 8 dev edition (Windows OS) and it displays fine. My prod server is running mx 7 (Linux) so it looks like rather then an Acrobat problem, it is a CF problem.
Lyndon, what kind of setup did you run this on?
I'm going to run a few more...
Scope your variables in var structs. This will make it easy to dump / debug exactly what you need.
For instance:
<cffunction name=".....>
<cfargument name=".......>
<cfset var temp = structNew()>
<cfset var results = structNew()>
<cftry>
<!--- do stuff --->...
ok this one has been burning my brain. If I have html that contains links, and try to output it as a PDF using cfdocument, a huge space and elongated underline beneath the link is always displayed and I cannot figure out how to fix this.
To my surprise, I haven't found anyone else complaining...
Here is a quick workaround, but I'm still not sure if there is a better way since this loop, albeit a small one, runs on each request:
<cfif not isDefined("request.app")>
<cfset request.app = structNew()>
</cfif>
<cflock type="readonly" scope="Application" timeout="10">
<cfloop...
Ok, I've having trouble deciding what would be the most efficient way to have variables accessible everywhere in an application.
I'm using an Application.cfc with cfmx 7, so my original idea (to make a deep copy of an application-scoped struct with duplicate() on each request to a...
The extra 'which FOO' parameter would have to suffice if I need a workaround.
What I meant by the super keyword not applying was that I can't somehow reference component1.FOO() like this:
objComponent2 = createObject("component", "component2.path");
objComponent2.super.FOO(params);
to use...
Thanks,
I seriously don't think overriding is what this guy had in mind .. just an oversight.
I was hoping there would be some way to refer (from the code where component 2 is instantiated) to component 1's FOO function, but as far as I know you can't. (super keyword doesn't apply there)...
Hi,
I was going over someone else's code and was wondering if this may pose a problem. (I'm not sure how CF deals with this internally)
Component 1 has a function named FOO.
Component 2 has a function named FOO.
Component 2 extends Component 1.
Will calls to that function simply take...
To avoid the scope issues that Tony mentioned, and to avoid temp variables (I just have a thing for them /OCD) I use the following .. works the same as Tony's but with my OCD added.
<cfoutput>
<cfloop from="1" to="#GetData.recordCount#" index="i">
<br><br>test0...
hmm ... If I understand correctly, depending on the web server, malformed or misunderstood header information could cause an error to be returned on request.
So it could be that cfhttp is throwing out bad headers with the request? (or more appropriately, considered bad by the server receiving...
I agree with Kevin on using stored procedures .. I use them a lot.
However, even at a point where I am all warm and fuzzy writing them, they can be cumbersome to debug (at least in MySQL 5)
Well worth the effort when it's a heavily used query and they're immune to them injections :)
-Steve
It might be worth mentioning that the webservice being used here is from http://www.holidaywebservice.com/ which is free and pretty handy for calendars. (If I could just figure out why I'm getting the failed responses from the production server now :-\)
If anyone knows of an alternative...
I'm having a hard time tracing the source of this one ...
I'm using cfhttp to retrieve an xml doc via a cfm page. It works fine on the two development servers, but suddenly it does not work on the production server.
Instead, it throws the following error:
[!]HTTP/1.1 400 Bad Request...
thanks for the response rac2.
For now I will probably do a case similiar to your example above. The query is a pretty complex join so I wanted to try and avoid building it as strings then executing it but it looks like if I want to make this truly dynamic it's the best way to go. (possible to...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.