I'd like to have a routing rule that accepted part of my domain name as a parameter. For example:
{name}.mydomain.com/photos/{id}
Is this even possible?
I erroneously wrote this code in python:
name = input("what is your name?")
if name == "Kamran" or "Samaneh":
print("That is a nice name")
else:
print("You have a boring name ;)")
It always prints out "That is a nice name" even when the input is neither "Kamran" nor "Samaneh".
Am I correct in saying that it considers "Samaneh" as a true? why?
By the way, I already noticed my mistake. The correct form is:
if name == "Kamran" or name == "Samaneh":
Hello,
I have just finished my application for iPhone. I would like to know if it is possible to use the word iPhone in the name of the application. For example, can I name my application iPhonesque ?
And for the icon, can I use graphics related to Apple like a Mac Windows (with the three buttons, red, yellow and green) on snow leopard background ?
Thank you very much for your answers.
I'm reading the Google Maps API and it states that the:
"callback: The function to call once the script has loaded. If using the Auto-loading feature, this must specify a function name, not a function reference.
What's the difference been a JavaScript function name vs a function reference?
http://code.google.com/apis/ajax/documentation/#GoogleLoad
Select user_name [User Name], first_name [First Name], last_name [Last Name]
Form tab_user
ORDER BY user_name
Select user_name [User Name], first_name [First Name], last_name [Last Name]
Form tab_user
ORDER BY User Name
Above are the two queries,
Is there any difference because of the user_name used instead of User NameIs there something that should be taken care/worried when using something like this.
I want to know about the name of all currently opened MS-Word file by its unique id.
I found unique id for one file but when I gave its destination path in code.
My requirement is that when any user open Word file then the unique id of this file is passed into my code and through this code the name of this file is stored into database (but it is done backgroundly and for multiple files).
Hi, so the thing is I'm using .htaccess to hide the index.php but I still get the controller name in the url like that: http://example.com/name_controller/about
My question is: is it possible to hide the name of the controller, so that only method is shown? hxxp://example.com/name_controller/about
i want to get the os information for the selected computer name or ip address.
i have the list view to display the computers name in LAN,How to get the Selected computer's
os details ie (which os,username of the computer)
how to do this in vb.net?
Is there any way in F# how to get a name of a variable passed into a function?
Example:
let velocity = 5
let fn v = v.ParentName
let name = fn velocity // this would return "velocity" as a string
Thank you in advance
When using this SQL query:
"Select * from table_name"
what happens if the name of the table contains blankspaces? Is there an special SQL sintax for selecting a table with a name such as "Author Code"?
Hi all, I'm working on file transfer application where client sends files to cpp server. At client side I can give the server's domain name but not IP address cuz it may vary. So any one can tell me how can I get my server's IP address through it's domain name. I have to put this logic into air application. Thank you.
I run into this frequently enough that I thought I'd see what others had to say about it.
Using the StyleCop conventions, I find that I often have a property name that is hard to make different than the class name it is accessing. For example:
public class ProjectManager
{
// Stuff here
}
public class OtherClass
{
private ProjectManager ProjectManager { get; set; }
}
It compiles and runs, but seems like it would be an easy way to confuse things, even with the use of "this".
I am working on a helper macro that look into the list function on a given module name on the active excel workbook.
Ex: I have a module name "Module1". Inside this module has the following function or sub
Sub Sub1()
End Sub
Sub Sub2()
End Sub
Function Func1()
End Function
Function Func2()
End Function
Is there a command or routine that can return the list of Function and Sub names?
What should I use:
/findby/name/{first}_{last}
/findby/name/{first}-{last}
/findby/name/{first};{last}
/findby/name/first/{first}/last/{last}
etc.
The URI represents a Person resource with 1 name, but I need to logically separate the first from the last to identify each. I kind of like the last example because I can do:
/findby/name/first/{first}
/findby/name/last/{last}
/findby/name/first/{first}/last/{last}
Dear all,
Using this below code i get the name only first 4 character.But i need the name except the last 4 character.
string fileName = Textbox1.text;
string newName = fileName.Substring(0, 4);
//ex: input abcdef.txt
//output:abcd
But i need output: abcdef
pls help!
thanks
Riad
I want to get the fine name with out the file extension in VIM.
I wrote the following functions in my .vimrc file for compile and run the Java program.
:function! JAVA_RUN()
:!javac %^M
:endfunction
map <F3> :execute JAVA_RUN()<CR> :source $HOME/.vimrc<CR>
In side the function how can I get the file name with out the extension.
In my code base I find that two modules have structures with the same name. It is giving a name conflict error. Is there a way to resolve it without changing the code?
From a "normal" person's perspective, I've heard many complaints about this company name being weird or awkward. As a programmer talking to another programmer, how does this name sound:
It is for a clothing company but the company is an online business hence the "tech" part of it.
http://www.------------.com
I want to get the fine name without the file extension in VIM.
I wrote the following functions in my .vimrc file for compile and run the Java program.
:function! JAVA_RUN()
:!javac %^M
:endfunction
map <F3> :execute JAVA_RUN()<CR> :source $HOME/.vimrc<CR>
In side the function how can I get the file name with out the extension.
i have tow tables in my database :
Users : contain user information
UserTypes : contain the names of user types ( student , teacher , specialist ) - I can't rename it to 'Types' as we have a table with this name
relation between Users and UserTypes many to many .. so i'll create a table that have UserID(FK) with UserTypeID(FK) but I try to find best name for that table ... any suggestion please ?
If A1 is [Jones,Mike], how can I get it to seperate but still use the first name as text in the other cell? Yes, text to columns would work greatly, but it does let me use the first name in a formula.
Hello,
I have a ejb module which contains my ejbs as well as web services. I am using Netbeans 6.8 and Glassfish V3
I right clicked on my web service and clicked "edit web service attributes" and then checked "secure service" and then selected keystore of my server. This is my sun-ejb-jar.xml file :-
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE sun-ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 9.0 Servlet 2.5//EN" "http://www.sun.com/software/appserver/dtds/sun-web-app_2_5-0.dtd">
<sun-ejb-jar>
<security-role-mapping>
<role-name>Admin</role-name>
<group-name>Admin</group-name>
</security-role-mapping>
<security-role-mapping>
<role-name>General</role-name>
<group-name>General</group-name>
</security-role-mapping>
<security-role-mapping>
<role-name>Member</role-name>
<group-name>Member</group-name>
</security-role-mapping>
<enterprise-beans>
<ejb>
<ejb-name>MemberBean</ejb-name>
<webservice-endpoint>
<port-component-name>wsMember</port-component-name>
<login-config>
<auth-method>BASIC</auth-method>
<realm>file</realm>
</login-config>
</webservice-endpoint>
</ejb>
</enterprise-beans>
</sun-ejb-jar>
Here MemberBean is my ejb and wsMember is my webservice.
Then i made another project and added web service client and again right clicked on "edit web service attributes" and gave password as test and test. This username and password (test) is in Glassfish server in file realm. But when i try to invoke my webservice i always get
SEC5046: Audit: Authentication refused for [test].
SEC1201: Login failed for user: test
What am i doing wrong? Am i missing something?
so i create in my view:
<%=date=Date.today%>
How do i get the name of the month out of the date? I was trying to do sth like
<%= DATE::ABBR_MONTHNAMES(date.month)%>
But without success. I keep getting an error: uninitialized constant ActionView::Base::CompiledTemplates::MONTHNAMES
How do i initialise the constant or is there any other way to get the name out of the Date format?
would greatly appreciate any answers!
If I have a cube divided into 8 smaller cubes, each of which may be subdivided into a further 8 cubes, ad infinitum, what is the name of my system?
I know that it's a special case of a tree, where each brance contains exactly 8 other leaves/branches.
I remember the name starting with "Oct", and there was a wikipedia article on it, but I honestly can't find it!
Does anyone know what such a data structure is actually known as?
I think the subject says it all. I always call it the "arrow operator", but I'm sure it has an official name. I quickly skimmed the C++ standard and didn't see it mentioned by name.