I have a DB with user accounts information.
I've scheduled a CRON job which updates the DB with every new user data it fetches from their accounts.
I was thinking that this may cause a problem since all requests are coming from the same IP address and the server may block requests from that IP address.
Is this the case?
If so, how do I avoid being banned? should I be using a proxy?
Thanks
Hi,
I have 1 UITabelView
I'm giving time to each and every row in cellForRowAtIndexPath: method
but when i'm doing up and down the UITabelView,at that time time overlaps of row from oneanother.
I have one UIButton. I put one image on that. When I click on that image, I get one view.
In that view, there is one UIButton and UIImageview. How can I move this view from Portrait to Landscape mode?
Ok SO, I have a user table and want to define groups of users together. The best solution I have for this is to create three database tables as follows:
UserTable
user_id
user_name
UserGroupLink
group_id
member_id
GroupInfo
group_id
group_name
This method keeps the member and group information separate. This is just my way of thinking. Is there a better way to do this? Also, what is a good naming convention for tables that link two other tables?
Hi,
is it possible to use date_sub like this ?
$dt = date("Y-m-d h:i:s");
$query = "INSERT INTO `table` (`date`) VALUES ('DATE_SUB('$dt', INTERVAL 15 DAY)')";
$result = MYSQL_QUERY($query);
Thanks
Which is a better way to select ans and quest from the table?
SELECT * FROM tablename WHERE option='ans' OR option='quest'";
OR
SELECT * FROM tablename WHERE option='ans' AND option='quest'";
Thanks so much!
Hello All,
I have a following ArrayList,
[Title,Data1,Data2,Data3]
[A,2,3,4]
[B,3,5,7]
And I would like to convert this one like this,
[Title,A,B]
[Data1,2,3]
[Data2,3,5]
[Data3,4,7]
I'm bit confused with the approach. Any hint would be much appreciated.
Thanks.
Supposed I have the following string:
string str = "<tag>text</tag>";
And I would like to change 'tag' to 'newTag' so the result would be:
"<newTag>text</newTag>"
What is the best way to do it?
I tried to search for <[/]*tag but then I don't know how to keep the optional [/] in my result...
I am looking an android Shared Preferences and I am wondering is there a way to just check if the preferences file exists.
SharedPreferences mySharedPreferences ;
mySharedPreferences=getSharedPreferences(“Name_of_your_preference”,mode);
This above code leads me to believe that "Name_of_Your_preferene" is stored as a file or some sort of container that will contain your preferences.
I am wondering is there away to check if this exists or not. When a user loads up an activity I want to save all the settings into this file with some default values(off for all settings). However I only want to do this if they are going to the page for the first time.
Otherwise if I would do something like this every time the page loads up
SharedPreferences.Editor editor= mySharedPreferences.edit();
/* now store your primitive type values. In this case it is true, 1f and Hello! World */
editor.putBolean(“myBoolean”,true);
editor.putFloat(“myFloat”,1f);
editor.putString(“myString”,” Hello! World”);
I am guessing it would override all settings even ones they set.
Hello,
In classic MVC the model notifies the view about changes made on it. In C# this means I have to subclass the View I'm interested in and in the subclassed class register to the model's event. For example,
if I were to implement MVC using C# and Winforms, I had to subclass TextBox class and then register inside the MyTextBox's constructor for the model events. Am I correct?
How was this issued in Smalltalk? Does one also need to subclass every View in order to register the model's events, or is there some way to dynamically add events to the views on the fly?
Thanks
I am using Eclipse IDE for C/C++ Developers, and i am using the gcc to compile at the moment. How can i change it to compile with a Green Hills compiler? Any help will be appreciated. Thanks!
Hi,
I test some simple F# code for "if" expression, but the result is unexpected for me:
> let test c a b = if c then a else b;;
val test : bool -> 'a -> 'a -> 'a
However
> test true (printfn "a") (printfn "b");;
a
b
val it : unit = ()
I'd expect only "a" is printed out but here I got both "a" and "b". I wonder why it comes out this way? Thanks!
Hi,
I have an NSMutableArray called playlist. This is in a method called getAllPlaylists. The code is something like this:
-(NSMutableArray *)getAllPlaylists
{
//playlist is an instance variable
playlist = [[NSMutableArray alloc] init]; //memory leak here
.
.
//some code here which populates the playlist array
[playlist addObject: object1];
.
.
return playlist;
}
The array allocation step of playlist is causing a memory leak. In such a scenario where can i release this array? Or can i avoid allocation n initialization of playlist here by doing something else?
Hello,
I would like to hear your suggestions on kind of design problem which I have in c#.
So, I am making a program where people can meet and draw in the same window over the internet or LAN. I am drawing into a bitmap and than I set it to a pictureBox component.
I have a hard time to decide how to send updates to each user, what is the best way to do it.
Should I send coordinates of mouse and than do the drawing on each users screen or stream the image to each. Maybe you know better solution to keep it synchronized and efficient.
Thank you.
hello, can somebody please explain the order of private and public is important or no?
for example:
class Account{
public:
Account(string firstName, string lastName, int id);
void printAccount();
private:
string strLastName;
string strFirstName;
};
will be the same as:
class Account{
private:
string strLastName;
string strFirstName;
public:
Account(string firstName, string lastName, int id);
void printAccount();
};
Hi,
I am trying extract number, from line has 'copies : 5' string.
this look behind expression not working.
echo "copies : 5" |perl -ne 'print $1 if /(\d+)(?
Thanks
I have been given a context schema for a database i need to make for my coursework but some of the attributes (column names) contain letters in brackets at the end of them such as:
*x_Number (Adm)
*x_Number (A)
*x_Number (P)
The problem is i have no idea what these letters mean!
Can anyone help?
Over the years, I've struggled with this. This year, there might be a solution.
I need a header, content and footer.
I would like the footer to be at the bottom of the page, the header at the top, and the content in between.
I would like the content to have a scroll bar.
Q: Is that too much to ask?