What is the best way to "NOT" display a page directly in php?
There is a page = register.php
a user cant open register.php directly. Only can access from index.php Register.php
Thanks
Hi, does anyone work on DOC1 designer tool, a Pitney bowes product. We use it at work for bill composition and later used on Mainframes. Please help me in finding out the best career path by means of this. Your help is highly appreciative.
URI.extract claims to do this, but it doesn't handle matched parens:
>> URI.extract("text here (http://foo.example.org/bla) and here")
=> ["http://foo.example.org/bla)"]
What's the best way to extract URLs from text without breaking parenthesized URLs (which users like to use)?
hi,
since eregi replace was deprecated on version 5.3 i want to make my program compatible with new version of php
http://php.net/manual/en/function.eregi-replace.php
so, i'm trying to use preg_replace like this
preg_replace(",",'','20,000.00');
but come with error
i'm familiar with eregi_replace(',','','20,000.00'); i'm not familiar with regex expression. what is the best replacement for eregi_replace?
In a pylons controller, I would like to first return the response to the request (so that the user gets a response ASAP), and then perform some additional operations (say, updating view counts, etc.) that didn't need to happen to generate the response. What's the best-practice for doing things like this?
Thanks!
Before you stone me for being a heretic, There is a sort that proclaims to be O(1), called "Bead Sort" (http://en.wikipedia.org/wiki/Bead_sort) , however that is pure theory, when actually applied I found that it was actually O(N * M), which is pretty pathetic.
That said, Lets list out some of the fastest sorts, and their best case and worst case speed in Big O notation.
~~ FlySwat ~~
I am trying to write some unit tests for a small web service written with Cherrypy and I am wondering what's the best way to figure out that the server has started, so i don't get connection refused if I try to connect too early to the service ?
Hi All,
I have a string say string s ="C:\\Data" , I have an array which contains some strings containg "C:\Data" in the beginning i.e. string[] arr = new {"C:\\Data\abc.xml","C:\\Data\Test\hello.cs"};.
I have to remove the string "C:\Data" from each entry and have to combine it with another string say string fixed = "D:\\Data".
What is the best way to do it, please help as I am a new programmer in C#.
Hi Everyone
As everybody knows the en-US Keyboard-layout is the best one for programming. So I'd like to use it in my IDEs. But since I live in a non-en-US country I need the de-CH layout for all other applications. Now I wonder if it is possible to set the layout depending to which application currently has the focus. If that is possible, can a human brain adapt to such a behaviour or is it just confusing?
cheers,
AC
In the excellent Secret Geek’s Building a Micro-ISV series, Leon Bambrick admits that he prefers to host his sites in the US because of the prices and proximity to his target market.
For Australian companies and start-ups, what’s the best ASP.NET web hosting in the country? Should a company consider hosting its website overseas even if the potential market is in here?
What is the best way to remember the Windows position between application loads using Obj-C? I am using Interface Builder for the interface, is it possible to do this with bindings.
What is the recommended method? Thank you.
What is Logically correct and W3C valid way to clear float?
zoom:1 is not valid by W3C and IE8 don't have hash layout problem
overflow:hidden and overflow:hidden
were not made to do this,as the spec
intended overflow to be used
<div class="clear"/> is not
semantically correct and i don't want to add extra markup.
clearfix hack generates content that
really hasn’t any semantic value.
I've asked many questions and read many articles on this issue but haven't find best way.
Hi! I'm writing a little website (webapp) in php+codeigniter, I'd really like to make it open source (to attract collaborators and to have a free VCS hosting).
Is that a good practice?
This mine security?
Which are the best tools to change important data before uploading? (like config files with db names and passwords used for testing etc..)
What's the best way to store language data?
Keep it as variables in some kind of lang.php file...
$l_ipsum = 'smth';
$l_rand = 'string';
Or select them from a database? I'm in search of your advice.
I need to securely crypt and decrypt information about users ( name, surname and user_id ) in cookies.
What is the best way to do this ? What encryption and decryption function do I need ?
Thanks ^_^
We are trying to create Flash online game)
Can you help me to choose the best way to communicate this two technology? Now I have chosen BlazeDS, but I am not sure, mb XML socket, or anything else.....
The desktop app should start the web server on launch and should shut it down on close.
Assuming that the desktop is the only client allowed to connect to the web server, what is the best way to write this?
Hi. We're building a site and wish to build for the same set of browsers Google Apps/Docs and YouTube support. Though not recommended, they seem to be detecting specific browsers/versions vs. features/functionality. What's the best way to support a minimum set of browsers while displaying a message to the users of older browsers to upgrade? What's the minimum set of browsers that the major sites are supporting? Thanks.
I have a custom TableCellRenderer which returns a JLabel as the renderer component.
Naturally the table cell now looks like a label and no longer like a table cell, which makes a difference especially when using Substance.
Is it possible to modify the label so that the LaF renders it like an ordinary table cell?
The best I could do was setting the background color of the label, but the borders and transition effets are missing.
I know its been asked many times already but no one could come up with solution so far.
The idea is to have one form separated into few steps and validate each step on next click of the button. I know jquery validation plugin is offering quite complicated way of doing it with accordion but can anyone come up with a simple solution something like
var stepOne = {
rules: {
fieldname1: "required",
fieldname2: "required",
}
}
$("form").validate(stepOne); //onclick
hope someone could suggest the best way of doing it.
Thanks.
what is the best way to extract last 2 characters of a string using regular expression.
For example, I want to extract state code from the following
"A_IL"
I want to extract IL as string..
please provide me C# code on how to get it..
string fullexpression = "A_IL";
string StateCode = some regular expression code....
thanks
Hi, I'm using boost::function for making function-references:
typedef boost::function<void (SomeClass &handle)> Ref;
someFunc(Ref &pointer) {/*...*/}
void Foo(SomeClass &handle) {/*...*/}
What is the best way to pass Foo into the someFunc?
I tried something like:
someFunc(Ref(Foo));
Hi everybody,
I tried to pass a filepath to a function in R, but I failed =/ I hope someone here can help me.
>heat <- function(filepath)
{ chicks <- read.table(file=filepath, dec=",", header=TRUE, sep="\t")
...
}
When I call the function, nothing happens...
>heat("/home/.../file.txt")
... and "chicks" is not found
>chicks
Error: Object 'chicks' not found
What is the correct way to pass a path to a function?
Best wishes from Germany,
Phil
I'm looking at the pros and cons of these three primary methods of coming up with primary keys for database rows.
So assuming I am using a database that supports more than one of these methods, is there a simple heuristic to determine what the best option would be for me?
How do considerations such a distributed/multiple masters, performance requirements, ORM use, security and testing have on the choice?
Any unexpected drawbacks that one might run into?
If you could organise your own programming meetup how would you organise the session so that people
had fun
learnt lots
were able to participate despite their level.
what kinds of topics, activities, challenges etc would you include (not all in one session but in general)
how would you handle differing levels?
what do you think are some important things to learn, to achieve?
Any input is greatly appreciated. Im not sure how Id mark the best answer, perhaps leave it to the community to vote for it.