In my project i have created a file upload.Now it is required that any exe file or exe file in a zip folder having .zip as extension, be prevented from being uploaded.
Can someoe suggest me a solution?
HOSTNAME=$1
#missing files will be created by chk_dir
for i in `cat filesordirectorieslist_of_remoteserver`
do
isdir=remsh $HOSTNAME "if [ -d $i ]; then echo dir; else echo file; fi"
if [ $isdir -eq "dir" ]
then
remsh $HOSTNAME "ls -d $i | cpio -o" | cpio -id
else
remsh $HOSTNAME "ls | cpio -o" | cpio -id
fi
done
i need simple solution for checking remote file is directory or file ?
thanks
Hi there
what would you use if you had to have a div box on your website that would have to be updated constantly with new HTML content from the server.
simple polling is probably not very resource inefficient - imagine also having 10'000 users and the div has to update.
what is the most efficient or elegant solution for such a problem?
are there existing widgets which contain this "autoupdate" functionality?
I'm using VS2010
I have a project with several headers and one file with the main() function.
For testing purposes I'd like to be able to easily another main() function that would instanciate different things than my original main.
Is there an easy way to define 2 "main" function, and easily switch between them?
The best would be to compile 2 binaries, one that starts at main1() and the other at main2(), or it can be a solution that requires to recompile some files, it doesn't matter
ContigSum(i,j) as the sum of the contiguous elements a[i] through a[j], i<=j and a[] contains +ve & -ve numbers
Could you please tell me a time efficient solution to find maximized contiguous SUM in the array?
Hi, I am trying to develop a cocoa application that requires to read highlighted text from any application. But so far I cannot find any decent solution because the accessibility API isn't always work. (e.g. Firefox) Does anyone know it is implemented in text-to-speech included in Leopard?
I have found this SO question but it isn't solved.
I'm working with several components that take color as a uint, but the colors I have are in the format of "#161616". I'm not sure what the relation between the 2 types of colors are or how to go from one to another.
It doesn't have to be an actionscript solution. I have only a small number of these colors, so can be done manually too.
I don't have access to my dev environment, but when I write the below:
interface IExample
void Test (HtmlControl ctrl);
class Example : IExample
{
public void Test (HtmlTextArea area) { }
I get an error stating the methods in the class implementation don't match the interface - so this is not possible. HtmlTextArea is a child class of HtmlControl, is there no way this is possible? I tried with .NET 3.5, but .NET 4.0 may be different (I am interested in any solution with either framework).
Thanks
i tried to search in google but no one talked about this.
i want a css solution to create a liquid tag box like the orange ones in this :
http://www.mixx.com/stories/10402914/haiti_us_gov_t_grants_matching_3_to_1_donations_to_worldvision_for_haiti
so, even if the word is long the tag box will fit it.
i want the same shape
Thanks
Hello,
Recently I needed to generate a huge HTML page containing a report with several thousand row table. And, obviously, I did not want to build the whole HTML (or the underlying tree) in memory. As result, I built the page with the old good string interpolation, but I do not like the solution.
Thus, I wonder whether there are Python templating engines that can yield resulting page content by parts.
i made a button & i used a on click event on this. So it can show some images. but after that when i click on another button for showing some text the images still upon there. Images hide the text. what will be the solution ?
Am a newbie to programming and have seen examples on dragging and dropping items from one list to another list using jQuery. My problem is that my list is populated dynamically and so i cannot predefine the list items. Can anyone provide a solution to this? Am working in Visualforce.Thanks in advance.
Hi all, having an issue generating random numbers in a loop. Can get around it by using Thread.Sleep but after a more elegant solution.
for ...
Random r = new Random();
string += r.Next(4);
Will end up with 11111... 222... etc.
Suggestions?
Hi Everybody, I really like Hudson CI and I do think it is the most useful and effective piece of software ever made for the Agile Application Lifecycle :-)
Anyway if the CI become unstable, the development is going to be really compromised, so keeping an eye on it is CRUCIAL !
Does anybody know about an effective solution for always monitoring it while you are "on the road" ? (maybe using your iPhone or iPod)
Hi! I was trying to split an arithmetic expression (eg "1+2+10+15") on the plus signs. However, I didn't manage to write the appropriate regular expression. I thought this would work:
expression.split("\\+");
but it doesn't. Do you know the correct solution?
Basically, this question with a difference...
Is it possible to capture print output from a TSQL stored procedure in .NET, using the Entity Framework?
The solution in the other question doesn't work for me. It works with the connection type from System.Data.SqlClient but I'm using the one from System.Data.EntityClient which does not have an InfoMessage event. (Of course, I could just create an SQL connection based on the Entity connection settings, but prefer to do it directly.)
Hi! I would like to insert a descriptive text inside an input element that disappers when the user click on it.
Example
I know it is a very common trick, but I do not know how to do that..
What is the simplest/better solution?
Is there a setting in jDeveloper 11g where the file of the code I'm seeing is automatically focused on the application explorer?
I'm specifically looking for the VS.NET setting "track active item in solution explorer"
The problem:
I have a set width and height image Lets say height:160px; width:200px; with an image in each box.
The image can vary in size but I need a solution that will always center the image vertically and horizontally within the box no matter what it's size.
Horizontal doesn't seem to be a problem by using margin: 0 auto but vertical is proving difficult. I have tried vertical align: center but this doesnt appear to work either
Any help is appriciated
Thanks
I am trying to parse a list of operating system instances with their unique identifiers. I am looking for a solution to parse a text string, and pass the values into two variables. The string to be parsed is as followed:
"Ubuntu 9.10" {40f2324d-a6b2-44e4-90c3-0c5fa82c987d}
I need to know whether SharePoint will restore the status of "activated" features when restoring from a catastrophic failure.
Presume the following
- Solution files are correctly deployed
- Config DB is unaffected
Specifically I am thinking at the webapp or site collection level.
Cheers!
I need to get informed when the user changes the font size in it's browser.
I need it to reposition some elements which have to be relative in one dimension to an anchor inside a text.
So far i haven't found anything and i'm a bit worried that it's not possible. In this case it should be possible to emulate it with a hidden div and some text inside and a script polling for changes of it's width. But i hope someone has a more elegant solution.
Is it possible to write a regular expression for finding a typical file matching pattern.
e.g. File<13/04/2010.txt should be picked up and not any other file.
i.e. Starting file name will be File followed by some dates and then the file extension.
If so, can we specify this pattern in the config file?
Looking for the solution in C#
Thanks
We have a server solution written entirely in unmanaged Visual C++. It contains complicated methods for really heavy data processing.
The whole thing contains millions lines of code, so rewritning it all in some other language is not an option. We could write some extra code or make isolated changes, but rewriting everything is out of the question.
Now we'd like to put it on a cloud. Which platform do we choose - Amazon EC2 or Windows Azure - and why?