Id
int64 1.68k
75.6M
| PostTypeId
int64 1
2
| AcceptedAnswerId
int64 1.7k
75.6M
⌀ | ParentId
int64 1.68k
75.6M
⌀ | Score
int64 -60
3.16k
| ViewCount
int64 8
2.68M
⌀ | Body
stringlengths 1
41.1k
| Title
stringlengths 14
150
⌀ | ContentLicense
stringclasses 3
values | FavoriteCount
int64 0
1
⌀ | CreationDate
stringlengths 23
23
| LastActivityDate
stringlengths 23
23
| LastEditDate
stringlengths 23
23
⌀ | LastEditorUserId
int64 -1
21.3M
⌀ | OwnerUserId
int64 1
21.3M
⌀ | Tags
list |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
4,438,586 | 1 | 4,438,634 | null | 0 | 778 | hi i have create one simple media player.... now its working fine. i retrieve video thumbnails in gallery. when i click the thumbnails video will play in other page... if i click thumbnails video play same page...see my screen shot....my video play in that red box...this type of frame how to create.....
this is my screen shot:
if i click thumbnails the video will play another page:
that screen shot:

this is for my coding:
```
public class videothumb extends Activity
{
private final static Uri MEDIA_EXTERNAL_CONTENT_URI =
MediaStore.Video.Media.EXTERNAL_CONTENT_URI;
private final static String _ID = MediaStore.Video.Media._ID;
private final static String MEDIA_DATA = MediaStore.Video.Media.DATA;
//flag for which one is used for images selection
private Gallery _gallery;
private Cursor _cursor;
private int _columnIndex;
private int[] _videosId;
private Uri _contentUri;
private int video_column_index;
protected Context _context;
/** Called when the activity is first created. */
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
_context = getApplicationContext();
setContentView(R.layout.main);
//set GridView for gallery
_gallery = (Gallery) findViewById(R.id.videoGrdVw);
//set default as external/sdcard uri
_contentUri = MEDIA_EXTERNAL_CONTENT_URI;
//initialize the videos uri
//showToast(_contentUri.getPath());
initVideosId();
//set gallery adapter
setGalleryAdapter();
}
private void setGalleryAdapter() {
_gallery.setAdapter(new VideoGalleryAdapter(_context));
_gallery.setOnItemClickListener(videogridlistener);
}
private void initVideosId() {
try
{
//Here we set up a string array of the thumbnail ID column we want to get back
String [] proj={_ID};
// Now we create the cursor pointing to the external thumbnail store
_cursor = managedQuery(_contentUri,
proj, // Which columns to return
null, // WHERE clause; which rows to return (all rows)
null, // WHERE clause selection arguments (none)
null); // Order-by clause (ascending by name)
int count= _cursor.getCount();
System.out.println("total"+_cursor.getCount());
// We now get the column index of the thumbnail id
_columnIndex = _cursor.getColumnIndex(_ID);
//initialize
_videosId = new int[count];
//move position to first element
_cursor.moveToFirst();
for(int i=0;i<count;i++)
{
int id = _cursor.getInt(_columnIndex);
//
_videosId[i]= id;
//
_cursor.moveToNext();
//
}
}catch(Exception ex)
{
showToast(ex.getMessage().toString());
}
}
protected void showToast(String msg)
{
Toast.makeText(_context, msg, Toast.LENGTH_LONG).show();
}
private AdapterView.OnItemClickListener videogridlistener = new OnItemClickListener() {
public void onItemClick(AdapterView parent, View v, int position,
long id) {
// Now we want to actually get the data location of the file
String [] proj={MEDIA_DATA};
// We request our cursor again
_cursor = managedQuery(_contentUri,
proj, // Which columns to return
null, // WHERE clause; which rows to return (all rows)
null, // WHERE clause selection arguments (none)
null);
//System.gc();
// video_column_index =
_cursor.getColumnIndexOrThrow(MediaStore.Video.Media.DATA);
_columnIndex = _cursor.getColumnIndex(MEDIA_DATA);
// Lets move to the selected item in the cursor
_cursor.moveToPosition(position);
String filename = _cursor.getString(_columnIndex);
Intent intent = new Intent(videothumb.this, ViewVideo.class);
intent.putExtra("videofilename", filename);
startActivity(intent);
showToast(filename);
// Toast.makeText(videothumb.this, "" + position, Toast.LENGTH_SHORT).show();
}
};
private class VideoGalleryAdapter extends BaseAdapter
{
public VideoGalleryAdapter(Context c)
{
_context = c;
}
public int getCount()
{
return _videosId.length;
}
public Object getItem(int position)
{
return position;
}
public long getItemId(int position)
{
return position;
}
public View getView(int position, View convertView, ViewGroup parent)
{
ImageView imgVw= new ImageView(_context);
try
{
if(convertView!=null)
{
imgVw= (ImageView) convertView;
}
imgVw.setImageBitmap(getImage(_videosId[position]));
imgVw.setAdjustViewBounds(true);
imgVw.setBackgroundColor(Color.WHITE);
imgVw.setLayoutParams(new Gallery.LayoutParams(150, 100));
imgVw.setPadding(5,5,5,5);
imgVw.setScaleType(ImageView.ScaleType.FIT_XY);
}
catch(Exception ex)
{
System.out.println("StartActivity:getView()-135: ex " + ex.getClass() +",
"+ ex.getMessage());
}
return imgVw;
}
// Create the thumbnail on the fly
private Bitmap getImage(int id) {
Bitmap thumb = MediaStore.Video.Thumbnails.getThumbnail(getContentResolver(),id,
MediaStore.Video.Thumbnails.MICRO_KIND, null);
System.out.println("ff"+MediaStore.Video.Thumbnails.
getThumbnail(getContentResolver(),id, MediaStore.Video.Thumbnails.MICRO_KIND, null));
return thumb;
}
}
}
```
coding 2:`
```
public class ViewVideo extends Activity {
private String filename;
private VideoView Video;
@Override
public void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
requestWindowFeature(Window.FEATURE_NO_TITLE);
getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
WindowManager.LayoutParams.FLAG_FULLSCREEN);
setContentView(R.layout.main1);
//setContentView(new Zoom(this));
Video=(VideoView)findViewById(R.id.VideoView01);
System.gc();
Intent i = getIntent();
Bundle extras = i.getExtras();
filename = extras.getString("videofilename");
Video.setVideoPath(filename);
Video.setMediaController(new MediaController(this));
Video.requestFocus();
Video.start();
}
}
```
anyone help me...
| how to play video in same page(media player) | CC BY-SA 2.5 | null | 2010-12-14T11:21:29.313 | 2011-03-15T15:19:13.547 | 2010-12-14T12:17:01.583 | 486,554 | 486,554 | [
"java",
"android",
"video",
"frame"
] |
4,438,696 | 1 | 4,440,884 | null | 3 | 9,957 | I have several Wpf pages in my project, these pages have different forms and ui control indide theme. The image below shows the mainWindow and there are two button.
I want to show a specific page when I click on + or Edit button using the Frame control which is highlighted.
apparenatly this woks:
```
Page1 me = new Page1();
mainFrame.Content = me;
```
But it has an IE navigation sound and a toolbar appears after going to page2.
any better way to show diffrent pages and not using a frame?

| A better way to show different wpf pages in mainWindow? | CC BY-SA 3.0 | 0 | 2010-12-14T11:35:32.957 | 2017-03-09T15:14:23.143 | 2017-03-09T15:14:23.143 | 1,033,581 | 263,723 | [
"wpf",
"user-interface"
] |
4,438,935 | 1 | null | null | 7 | 3,096 | I'm working on android application that will have basic image gallery functionality included. I've managed to build activity that fetches list of photos from my application backend API and render them in android gridview within activity layout.
This is how it looks like at the moment: 
However I'm having difficulties to build same gallery experience for user's device photos that were taken by camera and stored on device. Two solutions I considered were:
1. Building my own image gallery.
2. Starting default android image gallery using intent.
I belive that first solution will take me too much time to developed. I started with [this tutorial](http://androidsamples.blogspot.com/2009/06/how-to-display-thumbnails-of-images.html) but as soon I implemented it I found out that it is running too slow. Then I take a look at android camera [source code](http://android.git.kernel.org/?p=platform/packages/apps/Camera.git;a=summary) to find solution but again I found that it will take me too much time to review the code and to build my own gallery from scratch. I also believe that it is not in Android OS philosophy to rewrite functionalities that already exists but to use Intents to start activities that can handle actions you need. This lead me to second solution.
I tried calling default android gallery using intent in order to browse user's device photos by soon I was stuck again. Problem this time was that as soon as user tap on photo, gallery exits and returns to activity that originaly started it, and I expected (and I want) to start large image preview instead. I saw that others had this problem too [how to open gallery via intent without result](https://stackoverflow.com/questions/3864860/how-to-open-gallery-via-intent-without-result).
Because I didn't find the fix for this I decided to quit.
My question is how can I overcome these problems and build gallery that is similar to one I already have for web photos.
If anyone could give me reference I would be most thankful.
| How to implement custom device photos gallery for android? | CC BY-SA 2.5 | 0 | 2010-12-14T12:03:24.090 | 2016-02-29T01:01:43.997 | 2017-05-23T10:32:36.133 | -1 | 124,644 | [
"android",
"gridview",
"android-intent",
"gallery"
] |
4,438,943 | 1 | 4,445,764 | null | 20 | 39,612 | The challenge is to determine whether ASP.NET is enabled within IIS7 in a reliable and correct way.
Enabling/Disabling is done in this case by going into:
```
Server Manager ->
Roles ->
Web Server (IIS) ->
Remove Role Services ->
Remove ASP.NET
```
The natural place to determine this should be within the applicationHost.config file. However, with ASP.NET enabled or disabled, we still have the "ManagedEngine" module available, and we still have the isapi filter record in the tag.
The best I can find at the moment is to check if the <isapiCgiRestriction> tag includes the aspnet_isapi.dll, or that the ASPNET trace provider is available.
However these aren't detecting the presence of the ASP.NET config directly, just a side effect that could conceivably be reconfigured by the user.
I'd rather do this by examining the IIS configuration/setup rather than the OS itself, if possible, although enumerating the Roles & Services on the server might be acceptable if we can guarantee that this technique will always work whenever IIS7 is used.
Thanks for the responses. Clarifying exactly what I want to do, I'm pulling settings from a variety of places in the server's configuration into a single (readonly) view to show what the user needs to have configured to allow the software to work.
One of the settings I need to bring in is this one:

The one highlighted in red.
I don't need to manipulate the setting, just reproduce it. I want to see whether the user checked the ASP.NET box when they added the IIS role to the server, as in this example they clearly didn't.
I'd like to do this by looking at something reliable in IIS rather than enumerating the role services because I don't want to add any platform specific dependencies on the check that I don't need. I don't know if it will ever be possible to install IIS7 on a server that doesn't have the Roles/Services infrastructure, but in preference, I'd rather not worry about it. I also have a load of libraries for scrubbing around IIS already.
However, I'm also having trouble finding out how to enumerate the Roles/Services at all, so if there's a solution that involves doing that, it would certainly be useful, and much better than checking the side effect of having the ASPNET trace provider lying around.
Unfortunately, if you don't check the ASP.NET button, you can still get the ManagedEngine module in the IIS applicationHost.config file, so it's not a reliable check. You can also have ASP.NET mapped as an isapi filter, so checking them isn't enough. These things are especially problematic in the case where ASP.NET was installed but has been removed.
It looks like the best solution would be to examine the Role Services. However, API information on this is looking pretty rare, hence the cry for help.
| How to detect if ASP.NET is enabled in IIS 7 | CC BY-SA 2.5 | 0 | 2010-12-14T12:04:30.333 | 2018-01-19T08:38:09.637 | 2010-12-14T17:02:20.277 | 7,298 | 7,298 | [
"asp.net",
"iis",
"iis-7"
] |
4,439,020 | 1 | 4,442,156 | null | 3 | 3,127 | I created one web service application in windows phone 7. this is JSON array get from belowed uri.
...[{"id":4,"name":"Bangalore"},{"id":1,"name":"Chennai"},{"id":3,"name":"Hyderabad"},{"id":2,"name":"Mumbai"}]...
List item = (List)ds.ReadObject(msnew);
In this line one bug(it says while run).

There was an error deserializing the object of type.Data at the root level is invalid. Line 1, position 1.
coding:
public MainPage()
{
InitializeComponent();
}
```
[DataContract]
public class Item
{
[DataMember]
public int id
{
get;
set;
}
[DataMember]
public string name
{
get;
set;
}
}
private void PhoneApplicationPage_Loaded(object sender, RoutedEventArgs e)
{
WebClient wc = new WebClient();
wc.DownloadStringAsync(new Uri("http://75.101.161.83:8080/CityGuide/Cities?authId=CITY4@$pir*$y$t*m$13GUID*5"));
wc.DownloadStringCompleted += new DownloadStringCompletedEventHandler(wc_DownloadStringCompleted);
}
void wc_DownloadStringCompleted(object sender, DownloadStringCompletedEventArgs e)
{
string MyJsonString = e.Result;
// MessageBox.Show(e.Result);
DataContractSerializer ds = new DataContractSerializer(typeof(Item));
MemoryStream msnew = new MemoryStream(Encoding.UTF8.GetBytes(MyJsonString));
List<Item> item = (List<Item>)ds.ReadObject(msnew);
}
```
| How to Deserialize from web service JSON array or object? | CC BY-SA 2.5 | 0 | 2010-12-14T12:13:40.013 | 2012-09-29T05:22:41.263 | 2010-12-31T06:33:54.157 | 504,130 | 504,130 | [
".net",
"silverlight-4.0",
"c#-4.0",
"windows-phone-7"
] |
4,439,075 | 1 | 4,439,159 | null | 5 | 1,763 | I'm creating an application which visualises a picture frame as the user designs it. To create the frame I am drawing 4 polygons which represent the physical bits of wood and using a TextureBrush to fill it.
This works perfectly well for the left and top edges. However, for the bottom and right edges this method isn't working. It appears to me that the TextureBrush is tiling from the point (0,0) on the image and not within the polygon I've drawn. As a result, the tile doesn't line up with the polygon. By adjusting the size of the image I can get the tile to line up perfectly.
How do I create an arbitrarily positioned polygon and fill it with a tiled image, starting from the point (0,0) within the polygon, not the canvas?
I'm not attached to FillPolygon and TextureBrush if there is a better solution.
Example

| Create a polygon filled with a tiled image in c# | CC BY-SA 2.5 | 0 | 2010-12-14T12:19:50.947 | 2014-07-31T14:07:35.793 | null | null | 12,226 | [
"c#",
"system.drawing"
] |
4,439,180 | 1 | 4,439,253 | null | 0 | 373 | I am enclosing here the drawing of the RS-232 9 pin connection cable to link a XT2000i Blood analyser to a host PC. Is this just any serial port cable or a Null modem cable ?
Thanks. Chak.
Since @JTON said in the answer that other pins are not swapped, i am enclosing image of which pins are in use.

| Does this interface require a Null modem cable? | CC BY-SA 2.5 | null | 2010-12-14T12:33:29.150 | 2010-12-14T12:56:16.433 | 2010-12-14T12:56:16.433 | 49,189 | 49,189 | [
"serial-port"
] |
4,439,189 | 1 | 6,999,268 | null | 2 | 614 | Wa are talking about [Non-uniform rational B-spline](http://en.wikipedia.org/wiki/Non-uniform_rational_B-spline). We have some simple 3 dimentional array like
```
{1,1,1}
{1,2,3}
{1,3,3}
{2,4,5}
{2,5,6}
{4,4,4}
```
Which are points from a plane created by some B-spline
How to find controll points of spline that created that plane? (I know its a hard task because of weights that need to be calculated but I really hope it is solvable)
 For thouse who did not got idea of question - sory my writting is wwbad - we have points that are part of plane rendered here and we need to find controll points that form a spline which solution is that rendered plane.
| Finding 3 dimentional B-spline controll points from given array of points from spline solution? | CC BY-SA 2.5 | 0 | 2010-12-14T12:34:17.193 | 2011-08-09T16:05:23.173 | null | null | 434,051 | [
"math",
"3d",
"geometry",
"interpolation",
"approximation"
] |
4,439,211 | 1 | 4,440,020 | null | 0 | 2,311 | I am getting problem in alignment of element that is in FooterTemplate of GridView.
Anyone suggest me how to do it.The Code is:
```
<asp:GridView ID="gvComment" runat="server" AutoGenerateColumns="false"
OnRowDataBound="gvComment_RowDataBound" OnRowCreated="gvComment_RowCreated" Width="100%" ShowHeader="false" BorderWidth="0px" ShowFooter="true">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<table border="0" cellpadding="0" cellspacing="0" width="100%" >
<tr>
<td valign="middle" align="left" style="width:10%"><img id="imgUser" src="" alt="" title="" runat="server" /></td>
<td align="left" valign="top">
comment comment
<asp:Label ID="lblNameComments" runat="server" Visible="false" ></asp:Label>
</td>
</tr>
<tr><td colspan="2" style="height:7px;"></td></tr>
<tr>
<td colspan="2" style="padding-top:10px;background-image:url(../Images/dotted_line.jpg);background-repeat:repeat-x;background-position:center;"></td>
</tr>
<tr><td colspan="2" style="height:7px;"></td></tr>
</table>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<FooterTemplate >
<table border="0" cellpadding="0" cellspacing="0" width="100%" >
<tr>
<td align="left">
Footer Text
Footer Text
Footer Text
</td>
</tr>
</table>
</FooterTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
```
I have set align property of td left but it doesn't work.Page output shown in image.

| How to left align footer element in GridView | CC BY-SA 2.5 | null | 2010-12-14T12:36:19.683 | 2010-12-14T14:10:36.787 | null | null | 503,125 | [
"gridview",
"footer"
] |
4,439,268 | 1 | null | null | 8 | 3,350 | I have configured Sourcegear DiffMerge to be my default git merge tool using the following instructions:
```
git config --global diff.tool diffmerge
git config --global difftool.diffmerge.cmd "diffmerge \"\$LOCAL\" \"\$REMOTE\""
git config --global merge.tool diffmerge
git config --global mergetool.diffmerge.cmd "diffmerge --merge --result=\"\$MERGED\"
\"\$LOCAL\" \"\$BASE\" \"\$REMOTE\""
git config --global mergetool.diffmerge.trustexitcode false
```
Source: [http://www.andrejkoelewijn.com/wp/2010/01/08/configure-diffmerge-with-git/](http://www.andrejkoelewijn.com/wp/2010/01/08/configure-diffmerge-with-git/)
However when I run `git mergetool` I get the following error:

What could be the cause of this issue?
| Problem with git + DiffMerge on OS X | CC BY-SA 2.5 | 0 | 2010-12-14T12:43:07.370 | 2011-04-18T17:53:13.287 | null | null | 75,694 | [
"git",
"macos",
"diffmerge"
] |
4,439,537 | 1 | 4,450,577 | null | 30 | 54,854 | Working on a new site design in asp.net with master pages. Header of the page is a 35px tall "menu bar" which contains an asp menu control rendered as an unordered list.
The selected menu item is styled with a differenct colored background and 2px border around the left top and right sides. The bottom of the selected menu item should line up with the bottom of the menu bar so the selected "tab" looks as if it flows into the content beneath. Looks fine in firefox and IE but in chrome the "tab" seems to be 1 pixel higher than the bottom of the menu bar.
Just wondering if there is some sort of bug I dont know about.
I realize that you will most likely need code to help with this problem so ill post up the css as soon as possible.
EDIT:
here is the css for the menu...
```
div.hideSkiplink
{
width:40%;
float:right;
height:35px;
}
div.menu
{
padding: 0px 0px 0px 0px;
display:inline;
}
div.menu ul
{
list-style: none;
}
div.menu ul li
{
margin:0px 4px 0px 0px;
}
div.menu ul li a, div.menu ul li a:visited
{
color: #ffffff;
display: block;
margin-top:0px;
line-height: 17px;
padding: 1px 20px;
text-decoration: none;
white-space: nowrap;
}
div.menu ul li a:hover
{
color: #ffffff;
text-decoration: none;
border-top: 1px solid #fff;
border-right: 1px solid #fff;
border-bottom: none;
border-left: 1px solid #fff;
}
div.menu ul li a:active
{
background:#ffffff !important;
border-top:2px solid #a10000;
border-right:2px solid #a10000;
border-bottom: none;
border-left:2px solid #a10000;
color: #000000 !important;
font-weight:bold;
}
div.menu ul a.selected
{
color: #000000 !important;
font-weight:bold;
}
div.menu ul li.selected
{
background:#ffffff !important;
border-top:2px solid #a10000;
border-right:2px solid #a10000;
border-bottom: none;
border-left:2px solid #a10000;
}
div.menu ul li.selected a:hover
{
border: none;
}
```
The selected classes are added to the li and a elements via jquery...
Here is a screenshot of the problem...
The chrome example is on the top and u can see 1px of red border below the tab.
On the bottom is the firefox image where everything looks OK.

EDIT:
After playing around with this a bit more, I have discovered that it is actually the "header" div itself that is growing by 1px in chrome... This seems very strange to me.
| 1 pixel line height difference between Firefox and Chrome | CC BY-SA 2.5 | 0 | 2010-12-14T13:15:49.363 | 2016-01-20T08:03:54.433 | 2010-12-17T13:44:10.337 | 428,632 | 428,632 | [
"asp.net",
"css",
"firefox",
"google-chrome"
] |
4,439,798 | 1 | 4,439,895 | null | 13 | 3,011 | When I create a new file in Eclipse, there's a wide selection of different alternatives appearing in Eclipse.
However I am missing a couple of file which I need to open the "file create wizard" to create - JS files included.
How can I add my own file types as a default choice to appear in the "new files" menu?
Screenshot of the menu I am referring to:

| Eclipse IDE: Add/change default filetypes? | CC BY-SA 2.5 | 0 | 2010-12-14T13:46:44.903 | 2014-06-16T01:21:09.770 | null | null | 198,128 | [
"eclipse",
"ide",
"eclipse-pdt"
] |
4,439,894 | 1 | 4,800,315 | null | 7 | 1,350 | Is it possible to create 3D scatterplots in [sage](http://sagemath.org/)?
By scatterplot I mean graph like this:

| 3D scatterplots in sage | CC BY-SA 2.5 | 0 | 2010-12-14T13:55:49.317 | 2016-03-09T18:05:24.727 | null | null | 17,523 | [
"python",
"plot",
"sage"
] |
4,439,964 | 1 | null | null | 1 | 1,232 | I have a activity that I need to create, it contains two combo boxes that have the service that the activity is to call and then the method. Once the method is called I create a bunch of textboxes for the required parameters.

This works fine however I'm having problems databinding these dynamicaly created textboxes to the ModelItem for my activity
I see alot of stuff on-line about binding via xaml, but binding in code to ModelItem seems a bit sparse.
I appreciate any pointers!
| Custom Workflow activity designer - Binding expressionTextBox in code | CC BY-SA 2.5 | 0 | 2010-12-14T14:04:16.963 | 2010-12-18T11:45:06.317 | 2010-12-15T02:11:24.163 | 385,387 | 1,603 | [
".net",
"data-binding",
"workflow-foundation-4",
"workflow-activity"
] |
4,439,980 | 1 | 4,440,002 | null | 0 | 385 | I am trying to tint my UI to a nice brown. The pop up associated with the splitter is blackish-blue. How do I change its tint to the one I have applied to the rest of the app?
Here's a picture:

When I change the tint in IB it then looks like this:

| iPad Splitter - Popup Tint | CC BY-SA 2.5 | null | 2010-12-14T14:06:29.383 | 2010-12-14T14:42:13.293 | 2010-12-14T14:42:13.293 | 172,861 | 172,861 | [
"ipad",
"uisplitviewcontroller"
] |
4,440,024 | 1 | 4,682,165 | null | 0 | 177 | I have applied a brown tint to the app. When I select the popup then switch back to landscape view, the app goes back to the default tint. Is there a way to stop that.
here's a few screen shots in order:
1: looks good

2: Activate popup

3: Looses tint, reverts to default

| Loosing tint in iPad app after splitter popup activated | CC BY-SA 2.5 | 0 | 2010-12-14T14:11:36.483 | 2011-01-13T16:02:57.363 | null | null | 172,861 | [
"ipad",
"uisplitviewcontroller",
"tint"
] |
4,440,159 | 1 | 4,477,720 | null | 7 | 1,420 | Here is a sample of GAE Console log record:
 [http://i.stack.imgur.com/M2iJX.png](https://i.stack.imgur.com/M2iJX.png) for readable high res version.
I would like to provide a breakdown of the fileds, displayed both in the collpased (summary) view and the expended (detail) view. I will fill the fields I know their meaning and would appreciate assistannce with dichipering the rest. This post will be updated once new information is available.
Thank you,
Maxim.
---
Open issues:
- - -
| GAE/J request log format breakdown | CC BY-SA 2.5 | 0 | 2010-12-14T14:25:54.853 | 2010-12-18T10:55:43.363 | 2010-12-18T10:55:43.363 | 48,062 | 48,062 | [
"google-app-engine",
"console",
"cloud",
"logging"
] |
4,440,199 | 1 | 4,441,372 | null | 4 | 1,170 | are there any profilers which work well with Qt? I'd prefer free profilers for windows but any hint is appreciated.
I tried "Very Sleepy" and it works but I cant convince it to demangle the method names. Maybe I'm just doing wrong? Any pit-falls I'm not aware of?
Thank you very much!
Here's a screnshot of Very Sleepys output:

| Are there any Qt specific profilers around? | CC BY-SA 2.5 | 0 | 2010-12-14T14:30:05.540 | 2010-12-14T16:39:51.560 | 2010-12-14T15:10:49.820 | 366,299 | 366,299 | [
"qt",
"profiling",
"profiler"
] |
4,440,219 | 1 | 4,440,774 | null | 2 | 1,567 | i got a little problem, when launching my splitview in landscape, there is a little black space above my left view controller:

after rotating my ipad to portrait and switching back to landscape, the space is gone.
if i load the uitableviewcontroller directly into the left view, and not in a navigationcontroller, it works fine:

any ideas why this is happening ??
```
// Produkte
self.produkteMainTableVC = [[produkteMainTableViewController alloc] initWithStyle:UITableViewStylePlain];
UINavigationController *produkteMainNavigationController = [[UINavigationController alloc] initWithRootViewController:self.produkteMainTableVC];
self.produkteDetailVC = [[produkteDetailViewController alloc] initWithNibName:@"produkteDetailViewController" bundle:nil];
self.produkteSplitVC = [[UISplitViewController alloc] init];
self.produkteSplitVC.delegate = self.produkteDetailVC;
self.produkteMainTableVC.produkteDetailVC = produkteDetailVC;
[self.produkteSplitVC setViewControllers:[NSArray arrayWithObjects:produkteMainNavigationController,self.produkteDetailVC,nil]];
```
thanks for all help!
edit:
its exactly 20px like the statusbar. does that help anyone?
edit2:
doing something like this:
```
if(self.navigationController.navigationBar.frame.origin.y >= 20.0) {
self.navigationController.navigationBar.frame = CGRectMake(self.navigationController.navigationBar.frame.origin.x, 0.0, self.navigationController.navigationBar.frame.size.width, self.navigationController.navigationBar.frame.size.height);
}
```
results that:

a little improvement i would say. but i have no idea how to stick my tableview underneath the navigationbar.
| positioning problem with uisplitviewcontroller in left view | CC BY-SA 2.5 | 0 | 2010-12-14T14:32:10.593 | 2014-01-27T11:57:33.497 | 2010-12-14T16:45:28.930 | 253,288 | 253,288 | [
"objective-c",
"cocoa-touch",
"ipad",
"uinavigationcontroller",
"uisplitviewcontroller"
] |
4,440,872 | 1 | 4,440,902 | null | 1 | 1,878 | In , it states:

So I would expect the following code example to output since "objects are never copied but passed around by reference", so why does it output ?
```
var page_item = {
id_code : 'welcome',
title : 'Welcome',
access_groups : {
developer : '0010',
administrator : '0100'
}
};
page_item.access_groups.member = '0000';
var member = page_item.access_groups.member;
member = '1001';
$('p#test').html(page_item.access_groups.member); //should be "1001" but is "0000"
```
# Added:
@Gareth @David, thanks, this is what I was trying to show in this example, works:
```
var page_item = {
id_code : 'welcome',
title : 'Welcome',
access_groups : {
developer : '0010',
administrator : '0100'
}
};
var page_item2 = page_item;
page_item2.access_groups.developer = '1001';
$('p#test').html(page_item.access_groups.developer); //is '1001'
```
| Why does this Javascript example copy the variable value instead of pass by reference? | CC BY-SA 2.5 | 0 | 2010-12-14T15:38:40.950 | 2010-12-14T15:53:26.680 | 2010-12-14T15:47:21.310 | 4,639 | 4,639 | [
"javascript",
"pass-by-reference"
] |
4,441,040 | 1 | 4,442,356 | null | 0 | 499 | I currently have a Border that is bound to a MatrixTransform. When scrolling the mouse wheel, it will basically scale the MatrixTransform. Inside of the border, I have a Rectangle that is centered horizontally and vertically. At the time when the Border transform is scaled, I set the transform of the Rectangle to be equal to the Inverse of the Border. The ides is to keep the rectangle the same size and in the center. My current solution will keep the rectangle the same size, but it gradually moves away from center as you keep zooming. It seems as if the Rectangle transform isn't aware of the Border transform, does that make sense?
Here's a couple images, the first is initial, the second is after zooming a couple times (notice the rectangle stayed the same size, but it's no longer centered).


The basic idea that I'm trying to solve is like a Google maps application, when you zoom in, the city name size stays the same.
Here's all of my code, you should be able to pull this in and run it if you'd like:
MainPage.xaml
```
<UserControl x:Class="InvertedZoomTest.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:InvertedZoomTest"
mc:Ignorable="d">
<UserControl.DataContext>
<local:MainPage_ViewModel/>
</UserControl.DataContext>
<Border BorderBrush="Pink" Background="Gray" VerticalAlignment="Center" HorizontalAlignment="Center" BorderThickness="2" MouseWheel="Border_MouseWheel" Height="100" Width="100" RenderTransform="{Binding MainTransform}">
<Rectangle x:Name="rectangle" Canvas.Top="43" Canvas.Left="43" Fill="Red" Height="10" Width="10" HorizontalAlignment="Center" VerticalAlignment="Center" RenderTransform="{Binding TextTransform}"/>
</Border>
```
MainPage.xaml.cs
```
public partial class MainPage : UserControl
{
public MainPage()
{
InitializeComponent();
}
private MainPage_ViewModel viewModel
{
get
{
return this.DataContext as MainPage_ViewModel;
}
}
private void Border_MouseWheel(object sender, MouseWheelEventArgs e)
{
if (e.Delta > 0)
{
this.viewModel.ZoomRatio += .1;
}
else
{
this.viewModel.ZoomRatio -= .1;
}
this.viewModel.UpdateTextScale();
}
}
```
MainPage_ViewModel.cs
```
public class MainPage_ViewModel : INotifyPropertyChanged
{
public MatrixTransform TextTransform
{
get { return _textTransform; }
set
{
if (value != _textTransform)
{
_textTransform = value;
OnPropertyChanged("TextTransform");
}
}
}
private MatrixTransform _textTransform = new MatrixTransform();
public MatrixTransform MainTransform
{
get
{
return _mainTransform;
}
set
{
if (value != _mainTransform)
{
_mainTransform = value;
OnPropertyChanged("MainTransform");
}
}
}
private MatrixTransform _mainTransform = new MatrixTransform();
public void UpdateTextScale()
{
var scaleX = (double)(ZoomRatio);
var scaleY = (double)(ZoomRatio);
Matrix updatedMainTransformMatrix = new Matrix(scaleX, 0, 0, scaleY, 0, 0);
this.MainTransform.Matrix = updatedMainTransformMatrix;
OnPropertyChanged("MainTransform");
this.TextTransform = MainTransform.Inverse as MatrixTransform;
OnPropertyChanged("TextTransform");
}
public double ZoomRatio
{
get
{
return zoomRatio;
}
set
{
zoomRatio = value;
OnPropertyChanged("ZoomRatio");
UpdateTextScale();
}
}
private double zoomRatio = 1;
public event PropertyChangedEventHandler PropertyChanged;
public void OnPropertyChanged(string propertyName)
{
if (PropertyChanged != null)
{
PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
}
}
}
```
Am I doing something wrong that would make this rectangle move from the center? Any help would be greatly appreciated!
Out of curiousity, I wrapped a border around the rectangle and did an element to element binding on the width & height. You will notice in the image below that the transform on the rectangle seems to have an origin at the top left, does this make sense?
New XAML:
```
<Border BorderBrush="Pink" Background="Gray" VerticalAlignment="Center" HorizontalAlignment="Center" BorderThickness="2" MouseWheel="Border_MouseWheel" Height="100" Width="100" RenderTransform="{Binding MainTransform}">
<Border BorderBrush="Green" BorderThickness="1" Height="{Binding ElementName=rectangle, Path=Height}" Width="{Binding ElementName=rectangle, Path=Width}">
<Rectangle x:Name="rectangle" Canvas.Top="43" Canvas.Left="43" Fill="Red" Height="10" Width="10" HorizontalAlignment="Center" VerticalAlignment="Center" RenderTransform="{Binding TextTransform}"/>
</Border>
</Border>
```
Resulting Image:

| MatrixTransform inside MatrixTransform behavior is not what I was expecting | CC BY-SA 2.5 | null | 2010-12-14T15:52:04.870 | 2013-06-29T20:52:00.733 | 2013-06-29T20:52:00.733 | 1,714,410 | 331,463 | [
"silverlight",
"silverlight-4.0",
"zooming",
"transform",
"matrix-inverse"
] |
4,441,163 | 1 | 6,317,221 | null | 5 | 12,187 | WEKA Explorer can't open a connection to MySQL.
by the way: mysql driver was downloaded
mysql-connector-java-5.1.14-bin &
classpath was set.
(User & Pass are ok because it works with MySQL Workbench)
when clicking on the JButton OK (in the form 'Open DB'), then a message box shows an error
- see image:

(screen shot shows infamous "no driver" error)
weka version is 3.6.3.
any suggestions ?
| WEKA & MySQL Setup a connection | CC BY-SA 3.0 | 0 | 2010-12-14T16:02:22.717 | 2017-05-20T17:16:11.380 | 2012-05-08T20:35:15.420 | 41,782 | 508,717 | [
"mysql",
"connection",
"weka"
] |
4,441,462 | 1 | null | null | 0 | 116 | could you take a look at this piece of code coming from "Leaks instruments" : 
The tool indicates a memory leak in the string `temp` that is underlined dotted. Or .
Also, , but yet in the stacktrace this is the last call in my projects. I just want to correct this. Maybe I can't ?
Thanks in advance.
---
The leak did not show up .
I'm sorry but I forgot to mention the leak appeared in the simulator. I'm still curious if this is a known bug or something ?
| iPhone - yet another unsolvable memory leak | CC BY-SA 3.0 | null | 2010-12-14T16:27:02.993 | 2011-08-23T20:51:40.013 | 2011-08-23T20:28:56.113 | 1,288 | 429,766 | [
"iphone",
"memory-management",
"memory-leaks"
] |
4,441,474 | 1 | 4,441,538 | null | 0 | 1,339 | I'm not sure if I have worded this question properly I will explain what I am trying to acheieve further.
I am looking to create a graphical representation of an existing database showing table relationships Key relationships etc.
I have seen posts around the internet that suggest you can just go; New > Database Diagram. But I have seen nothing to this effect in Management Studio
Something similar to this:

| Is there an easy way to create a database diagram in SQL Server | CC BY-SA 2.5 | null | 2010-12-14T16:27:47.177 | 2010-12-24T05:36:55.400 | null | null | 155,476 | [
"tsql",
"diagram"
] |
4,441,568 | 1 | 4,442,630 | null | 1 | 60 | When I use `describe-function`, I get the documentation text displayed in a Help buffer.
If the doc is long enough, it will wrap in the buffer, but it doesn't wrap nicely. like this:

I can make the docstring use 72-character lines, but that supposes that the window will be 80 characters, which is not always the case.
Is it possible to get `describe-function` to emit documentation in a more nicely formatted way?
| Is it possible to more nicely format the help for a function? | CC BY-SA 2.5 | null | 2010-12-14T16:34:40.153 | 2011-08-20T18:49:34.927 | null | null | 48,082 | [
"emacs"
] |
4,441,721 | 1 | null | null | 1 | 117 | I'm having a problem with a textarea and submitbuttons in my form.
Here's a first screenshot of a seemingly normal situation:

And here's what happens if I set the textarea to have 30 columns:

The textarea just went right over the buttons. I'd expect the buttons to be pushed down. Or anything below it, for that matter. What do I need to set to make this happen?
| Problems css height and positioning of text fields in form | CC BY-SA 2.5 | 0 | 2010-12-14T16:45:18.727 | 2010-12-14T16:48:25.783 | null | null | 80,907 | [
"css"
] |
4,441,930 | 1 | 4,442,124 | null | 2 | 689 | So the old JavaScript aficionado and the young jQuery wizard in me are having a little disagreement. `onClick``bind()``click()` I find myself & myself disagreeing on this topic quite often, so I thought I would try generate some discussion on the issue. To explain the issue, the pattern below seems to bring this to the forefront most often.
## Typical Example
---
I'm writing a search for a member directory. On my interface I have various filter criteria like "gender", "member since", and "has profile photo". A criteria looks like this ...

- -
My html ends up looking something like ...
```
<div id="FilterContainer_GenderDIV">
<span id="FilterLabel_Gender">Gender:</span>
<span id="FilterSelection_Gender">Any</span>
<span id="FilterChicklet_Gender" class="sprite_MediumArrowDown inline" ></span>
<div id="FilterOptions_GenderDIV">
<input type="radio" id="GenderID" name="GenderID" value="1"/> <a href="" id="FilterOptionLink_CoupleGender_1" >Male</a><br />
<input type="radio" id="GenderID" name="GenderID" value="2"/> <a href="" id="FilterOptionLink_CoupleGender_2" >Female</a><br />
<input type="radio" id="GenderID" name="GenderID" value="0" checked="checked"/> <a href="" id="FilterOptionLink_CoupleGender_0" class="SearchSelectedChoice" >Any</a><br />
</div>
```
The issue really arises when a user clicks on the text link. At that point I need to know which radio set to change,which link text to bold, and take the newly selected text and change my header label. I see a few options for making this type of scenario work.
## Options for making it work
---
I can use jQuery to bind to my elements in a generic fashion. `$('#FinderBodyDIV input:radio').click(SearchOption_Click);` Then sort out the appropriate ID & text with clever dom inspection. For example, name my hyperlink could be named `GenderID_Link_1` where `1` is the ID I should select and `GenderID` tells me which radio set to change. I could use a combination of '.parents()``.find()`and`.siblings()` to find the radio next door and set it with the ID.
- -
An alternate option is to gather up my set of elements and for each individual element do a 'bind()' passing eventData.
```
var elements = $('#FinderBodyDIV input:radio');
elements.each ( FunctionWithLogicToBindPassingEventData );
```
- - -
This is where my old JavaScript inclinations keep taking me. Instead of using jQuery to inject bindings, I change my link/radio button HTML to include click handlers. Something like ...
```
<input type="radio" id="GenderID" name="GenderID" value="1" onClick="SetGender(1,'Male')"/> <a href="" id="FilterOptionLink_Gender" onClick="SetGender(1,'Male')">Male</a><br />
```
- - - -
## So what's a boy to do?
---
This seems like a fairly common scenario. I find it pops up in quite a few situations besides the one I've described above. I've searched tubes on the interweb, blogumentation, and technical articles on twitter. Yet, I don't see anyone talking about this issue. Maybe I just don't know how to phrase the issue. Whatever the reason, I don't feel good about any of the solutions I've come up with.
It really comes down to how do I associate a clicked element with it's related data--JSON, embedded in HTML names, or otherwise. So what's your take?
| JQuery parameter injection on bind/click vs. embedded click handlers with parameters | CC BY-SA 3.0 | null | 2010-12-14T17:05:42.880 | 2012-02-17T23:40:28.977 | 2012-02-17T23:40:28.977 | 13,578 | 215,068 | [
"javascript",
"jquery",
"standards"
] |
4,442,126 | 1 | 4,444,039 | null | 50 | 36,793 | I'm trying to get a "speech bubble" effect similar to the one in Mac OS X when you right click on something in the dock. Here's what I have now:

I need to get the "triangle" part of the lower portion. Is there any way I can draw something like that and get a border around it? This will be for an app.
Thanks in advance!

| How to draw a "speech bubble" on an iPhone? | CC BY-SA 2.5 | 0 | 2010-12-14T17:26:42.557 | 2021-02-25T13:31:00.477 | 2015-11-26T16:47:17.357 | 3,140,927 | 456,851 | [
"ios",
"objective-c",
"iphone",
"uiview",
"uibezierpath"
] |
4,442,363 | 1 | 4,449,757 | null | 1 | 357 | Currently, I have 2 repository. One repository is named `jstock`, which contains all the stable source code.
Another repository named `jstock-refactor-calendar-to-joda`, which is cloned from `jstock`, and it contains all the unstable experimental feature code.
All the change-set in red rectangle is unstable experimental feature code. They are not finished yet. Hence, I do not have intent to make it merge with the change-set in green rectangle (Green rectangle indicates those are stable change-set)
After `jstock-refactor-calendar-to-joda` pulls from `jstock`, here is how it looks like.

Now, I would like to let the experimental code visible to `jstock` (But not going into default line, as they are unstable)
Hence, when I perform push from `jstock-refactor-calendar-to-joda` to `jstock`, here is what I get.

This not what I want. In `jstock`, I wish the stable code (in green rectangle) remains in default (left side), unstable code (in red rectangle) remains in right side. Note that, I do not want them to be merged yet, but I would like to have both development lines (stable and unstable) being visible.
Is there any step I had done wrong?
| Prevent unstable code going into default line | CC BY-SA 2.5 | 0 | 2010-12-14T17:51:12.973 | 2012-03-30T12:16:49.193 | 2012-03-30T12:16:49.193 | 110,204 | 72,437 | [
"mercurial",
"workflow",
"dvcs",
"branching-and-merging"
] |
4,442,381 | 1 | 4,442,480 | null | 3 | 3,010 | I am trying to databind a ribbon control for dynamic menus.
```
<ribbon:Ribbon>
<ribbon:RibbonTab Header="Reports"
ItemsSource="{Binding ReportMenus}"
ItemTemplate="{StaticResource RibbonGroupDataTemplate}">
</ribbon:RibbonTab>
<ribbon:RibbonTab Header="Test">
<ribbon:RibbonGroup Header="TestGROUP"
ItemsSource="{Binding ReportMenus}"
ItemTemplate="{StaticResource RibbonButtonDataTemplate}">
</ribbon:RibbonGroup>
</ribbon:RibbonTab>
</ribbon:Ribbon>
```
The top ribbon tab is my 'real' ribbontab. The bottom started out as a manually built that I am verifying my theories with.
Here are the datatemplates I am trying to use:
```
<Style TargetType="{x:Type ribbon:RibbonButton}">
<Setter Property="Label"
Value="{Binding ReportDisplayName}" />
</Style>
<DataTemplate x:Key="RibbonButtonDataTemplate">
<ribbon:RibbonButton />
</DataTemplate>
```
This is my first attempt at the Group DataTemplate:
```
<HierarchicalDataTemplate x:Key="RibbonGroupDataTemplate" DataType="{x:Type Ribbon:RibbonGroup}"
ItemsSource="{Binding Converter={StaticResource DebugConverter}}"
ItemTemplate="{StaticResource RibbonButtonDataTemplate}">
<TextBlock Text="{Binding Path=ReportDisplayName}" />
</HierarchicalDataTemplate>
```
Then I was trying this one:
```
<DataTemplate x:Key="RibbonGroupDataTemplate">
<ribbon:RibbonGroup ItemsSource="{Binding Converter={StaticResource DebugConverter}}"
ItemTemplate="{StaticResource RibbonButtonDataTemplate}" />
</DataTemplate>
```
The problem is that I cant get the buttons to show up under the group. If I dont have a grouptemplate as in my second ribbontab, I can get it working.
But if I try to do the group dynamically as well it fails to create the buttons. Also by doing the datatemplate with the ribbongroup inside of it, the headings get cutoff. I already read about that and that was the reason for trying to use the HierarchicalDatatemplate. The Regular Datatemplate does not allow for itemsource or itemtemplate.
So How do i get a dynamic RibbonGroup to show Dynamic RibbonButtons?
---
I have implemented some other changes now and its at least filling it in, however its not correct.
Right now it looks like this:

I want it to look like this which is partially hardcoded.

here is the xaml
```
<DataTemplate x:Key="RibbonButtonDataTemplate">
<ribbon:RibbonButton />
</DataTemplate>
<HierarchicalDataTemplate x:Key="RibbonGroupDataTemplate"
DataType="{x:Type ribbon:RibbonGroup}"
ItemsSource="{Binding ReportsMenuCollection}"
ItemTemplate="{StaticResource RibbonButtonDataTemplate}">
<TextBlock Text="{Binding Path=ReportDisplayName}" />
</HierarchicalDataTemplate>
```
the only thing I have left to try is changing my RibbonButtonDataTemplate to a hierarchical datatemplate.
| Building wpf Ribbon at runtime | CC BY-SA 2.5 | 0 | 2010-12-14T17:53:16.480 | 2010-12-14T20:49:23.547 | 2010-12-14T20:49:23.547 | 183,408 | 183,408 | [
"wpf",
"ribbon",
"ribbon-control"
] |
4,442,915 | 1 | 4,442,991 | null | 8 | 35,080 | I am a relative newby to EF and have created a simple model (see below) using EF4.

I am having a problem inserting a new record into the UserRecord entity and subsequently adding the UserDetail entity which uses the newly created UserRecordId as its primary key. The code shown below used to work when my database had a one-to-many relationship but when I change this to a one-to-one relationship I get the error highlighted in the image below.

I believe its not working as there is now no UserDetails property associated with the UserRecord because it’s now a one-to-one relationship. My question is how do I now insert new UserRecord and corresponding UserDetail entities with a one-to-one relationship?
Any help on this one is much appreciated as have been on searching the web and trying a variety of different things without success.
Cheers
Cragly
| Entity Framework – Inserting into multiple tables using foreign key | CC BY-SA 2.5 | 0 | 2010-12-14T18:44:06.910 | 2015-05-10T16:07:57.453 | null | null | 109,288 | [
"entity-framework",
"entity-framework-4"
] |
4,442,986 | 1 | 4,443,020 | null | 0 | 4,873 | I have a text in photoshop with font: "Arial 17 regular strong" how can I write it in css to show the same?
My 2 problems are:
1- the pt unit in photoshop, what is it in css?
2- if the font is bold strong in photoshop, how it will look like in css?

| How to show the same font which in photoshop on my webpage? | CC BY-SA 2.5 | null | 2010-12-14T18:51:44.157 | 2013-02-04T10:28:12.483 | 2010-12-14T19:11:07.580 | 20,126 | 20,126 | [
"html",
"css",
"fonts",
"photoshop"
] |
4,443,255 | 1 | 4,443,549 | null | 0 | 628 | I am trying to build a quick search box. it is basically a widget. Upon clicking, it pops up the quick search box and launch the browser with query string. No activity except searchactivity.
And also added codes for 'recent query suggestion' But having a problem to have menu for 'clear history' Here is what I wanted to implement. When quick search box is displayed, by pressing menu button, I want option menu to be popped up, keypad to be disappeared, quick search box to be stayed.
the implementation of google sample code - Searchable dictionary is not what I want to implement. It starts an activity with instruction message and when a user presses the search button or menu button, it pops up the quick search box. Mine is when it runs from a widget, the quick search box is popped up right away just like the google search widget.
How can I override onCreateOptionMenu on searchmanager? Or is there any way to activate option menu when the searchmanager is activated?
Please take a look at the images below. the second image is what I want to implement upon clicking menu button.


| How to activate option menu when search box is displayed? (SearchManager) | CC BY-SA 2.5 | null | 2010-12-14T19:22:36.173 | 2010-12-14T19:54:33.977 | null | null | 419,893 | [
"android",
"search"
] |
4,443,628 | 1 | 4,453,091 | null | 1 | 266 | Below is an image of the sections I'm talking about:

What I'm doing is very similar to eBay:
1) a form at the top for "search terms" and then a category.
2) filters on the left that a user can click to refine the search even further.
3) sorting those results.
I played with eBay a bit and it looks to me like they are posting back every time a filter (box on the left) is clicked, or when they sort the results. Do they then store a copy of all the "settings" used to display the page in the form and use that to post back on a submit click?
How can I emulate this functionality? I don't like the idea of wrapping an entire page in a `form` element... it seems dirty. Should I use jQuery to collect all of the user input and then somehow pass it along?
| ASP.NET MVC 2: Emulating eBay Postback | CC BY-SA 2.5 | null | 2010-12-14T20:04:15.317 | 2010-12-15T17:41:45.477 | 2010-12-14T20:13:31.903 | 337,806 | 337,806 | [
"asp.net-mvc-2",
"postback"
] |
4,443,824 | 1 | 4,447,493 | null | 5 | 27,570 | How can I get a list of users within an LDAP group, even if that group happens to be the primary group for some users?
For example, suppose "Domain Users" is "Domain Leute" in German. I want all members of "CN=Domain Leute,DC=mycompany,DC=com". How would I know that is the well-known "Domain Users" group?
Or what if some users' primary group was changed to "CN=rebels,DC=mycompany,DC=com", and I wanted to get members of THAT group? Users don't have a memberOf property for their primary group, and the primary group won't have a member property listing them.
This is what I see when viewed via LDAP (ie, no MS extensions):

| LDAP group membership (including Domain Users) | CC BY-SA 2.5 | 0 | 2010-12-14T20:23:38.060 | 2017-01-20T12:44:42.257 | 2010-12-16T14:41:03.130 | 7,442 | 7,442 | [
"active-directory",
"ldap",
"member",
"adsi",
"ldap-query"
] |
4,443,989 | 1 | 4,444,512 | null | 1 | 1,638 | I have this tableview in my app which has a particular item name such as "Apple". When the user taps on that selected item they are directed to a detailView that views an image and description of that selected item. I was thinking to use plist´s to do this, but I don't know how to. Please help me.
I looked at some sources such as iCodeBlog but they don´t really explain retrieving and saving so well. Maybe you people can also give reference to some links that describe this better.
Heres a plist that I have tried. Each of the items (Orange, Apple) have the data that I want to display in my detailView. I basically want to display the data shown.

| Using plist in a DetailView | CC BY-SA 2.5 | 0 | 2010-12-14T20:39:59.863 | 2019-05-23T17:46:18.157 | 2010-12-15T13:21:12.447 | 488,876 | 488,876 | [
"iphone",
"sdk",
"plist",
"tableview"
] |
4,444,101 | 1 | 4,444,501 | null | 1 | 594 | I have a ListView that has a subtle gradient bitmap in the background of each item. I noticed that when I scroll the list, the background gradient becomes banded and changes color. The gradient is a dark gray and when it scrolls is becomes subtly green and banded. It basically looks like the quality of the images greatly decreases as it scrolls.
Most of the time, as soon as it finishes scrolling, it returns to the normal quality. Sometimes it actually stays poor quality even after scrolling stops. On a Nexus One it almost always stays low quality after scrolling.
Is there a way to avoid this?
Note: This is not the common ListView background problem discussed here: [http://developer.android.com/resources/articles/listview-backgrounds.html](http://developer.android.com/resources/articles/listview-backgrounds.html)
Here is an enlarged screen cap to show the difference. On the left side is the background normally. On the right half you can see what it looks like when it scrolls.

| Bitmap colors change while scrolling | CC BY-SA 2.5 | null | 2010-12-14T20:52:31.390 | 2010-12-14T22:11:02.880 | 2010-12-14T22:11:02.880 | 445,348 | 445,348 | [
"android"
] |
4,444,107 | 1 | null | null | 1 | 746 | I'm writing a java servlet on AppEngine. This servlet generates png images. I would like to "gzip" the response. I do it this way:
```
resp.setHeader("Content-Encoding","gzip");
resp.setContentType("image/png");
// ... png generation ...
GZIPOutputStream gzos = new GZIPOutputStream(resp.getOutputStream());
gzos.write(myPNGdata);
gzos.close();
```
But: in development server, it's ok, the png displays fine and the response is well gzipped. Then I test on production server (AppEngine) and all I get is a "broken" image...

What could be wrong with my code? Is it related to dev/prod environment?
Off course, If I don't gzip the output, it's ok in both environments.
Thanks for any help.
---
Edit: I tried this too:
```
GZIPOutputStream gzos = new GZIPOutputStream(resp.getOutputStream());
gzos.write(ImagesServiceFactory.makeImage(readImage("somePicture.png")).getImageData());
gzos.flush();
gzos.finish();
gzos.close();
```
and it doesn't work either.
---
Edit 2: in fact, the response is gzip. I fetched the servlet with "curl theUrl > tmp.gz", then I gunzip "tmp.gz", and the image is fine. But no browser can display it correctly :( What's wrong with my gzip?
| GZipOutputStream & appengine | CC BY-SA 2.5 | 0 | 2010-12-14T20:52:54.593 | 2013-02-01T16:06:33.280 | 2013-02-01T16:06:33.280 | 1,439,305 | 446,576 | [
"java",
"google-app-engine",
"servlets",
"gzip",
"gzipoutputstream"
] |
4,444,421 | 1 | 4,453,067 | null | 3 | 21,622 | I'm trying to convert a byte[] to an image in C#. I know this question has been asked on different forums. But none of the answers given on them helped me. To give some context=
I open an image, convert it to a byte[]. I encrypt the byte[]. In the end I still have the byte[] but it has been modified ofc. Now I want to display this again. The byte[] itself consists of 6559 bytes. I try to convert it by doing :
```
public Image byteArrayToImage(byte[] byteArrayIn)
{
MemoryStream ms = new MemoryStream(byteArrayIn);
Image returnImage = Image.FromStream(ms);
return returnImage;
}
```
and I get this error: Parameter is not valid.
The byte array is constructed by using the .toArray() on a List
```
List<byte> encryptedText = new List<byte>();
pbEncrypted.Image = iConverter.byteArrayToImage(encryptedText.ToArray())
```
;
Can anyone help me? Am I forgetting some kind of format or something ?
The byte that has to be converted to an image :

```
private void executeAlgoritm(byte[] plainText)
{
// Empty list of bytes
List<byte> encryptedText = new List<byte>();
// loop over all the bytes in the original byte array gotten from the image
foreach (byte value in plainText)
{
// convert it to a bitarray
BitArray myBits = new BitArray(8); //define the size
for (byte x = 0; x < myBits.Count; x++)
{
myBits[x] = (((value >> x) & 0x01) == 0x01) ? true : false;
}
// encrypt the bitarray and return a byte
byte bcipher = ConvertToByte( sdes.IPInvers(sdes.FK(sdes.Shift(sdes.FK(sdes.IP(myBits),keygen.P8(keygen.shift(keygen.P10(txtKey.Text))))),keygen.P8(keygen.shift(keygen.shift(keygen.shift(keygen.P10(txtKey.Text))))))));
// add the byte to the list
encryptedText.Add(bcipher);
}
// show the image by converting the list to an array and the array to an image
pbEncrypted.Image = iConverter.byteArrayToImage(encryptedText.ToArray());
}
```
| Convert a Byte array to Image in c# after modifying the array | CC BY-SA 2.5 | 0 | 2010-12-14T21:29:00.413 | 2012-04-13T11:48:57.833 | 2010-12-14T21:51:22.103 | 329,829 | 329,829 | [
"c#",
"image",
"byte"
] |
4,444,560 | 1 | 4,444,673 | null | 3 | 1,420 | Given a directed graph, what is an algorithm I can use to find a random subset of its edges so that every node has exactly one incoming and exactly one outgoing edge?
For example, this could be the graph I am given:

And this would be a valid output graph:

This is valid because:
- - -
If there is no possible solution that should be detected.
Is there an efficient algorithm to solve this?
Thanks!
| Graphing Algorithm To Match Nodes | CC BY-SA 2.5 | 0 | 2010-12-14T21:44:12.637 | 2010-12-14T21:59:16.817 | null | null | 284,685 | [
"java",
"algorithm",
"graph",
"matching",
"graph-algorithm"
] |
4,444,983 | 1 | 4,537,184 | null | 0 | 149 | Consider the TFS wizard when creating a new Team Project in Team Foundation Server 2010.
The default option is "".
Is there an option somewhere in the TFS Admin Console, registry, or a Powershell command to have the default set to "" ?

| default New Team Project to NOT create a SharePoint site | CC BY-SA 2.5 | null | 2010-12-14T22:34:19.887 | 2010-12-27T07:21:03.140 | 2010-12-15T14:33:42.030 | 21,234 | 23,199 | [
"tfs"
] |
4,445,133 | 1 | 4,445,171 | null | 8 | 6,453 | So in [this simple example](http://www.jsfiddle.net/Trufa/hupwM/) I have as final result:

This is a very simple question but I simply can't get my head around it.
To achieve the vertical centering of the numbers I used:
```
line-height:100px;
```
Which works great and have been doing it trial and error basis.
My question is specifically why the `line-height:50px;` just gets if half of the way.
If the `small` `div` has a height of `100px` and I an positioning relative to it, shouldn't the half of it center it to the half.
This specially puzzles me since, [when I center a div](http://www.jsfiddle.net/Trufa/hupwM/4/):
I would use: `margin:50px 0 0 50px;` to get this:

---
I realize this question might be an overkill since the answer might be (probably will be very simple), so sorry! but I guess it is better the "why doesn't this work" questions ;)
Thanks in advance!!
| CSS - Line height property, how it works (simple) | CC BY-SA 2.5 | null | 2010-12-14T22:57:39.457 | 2010-12-14T23:21:18.913 | null | null | 463,065 | [
"html",
"css",
"alignment",
"vertical-alignment"
] |
4,445,201 | 1 | 4,445,297 | null | 5 | 222 | 
See attached image. How is this accomplished? Gosh, I've been going CSS for 8 years but somehow never had to do this!
Thanks!
| CSS: Special Fluid Layout Problems | CC BY-SA 2.5 | null | 2010-12-14T23:07:20.960 | 2015-02-18T01:48:54.450 | 2010-12-14T23:15:15.530 | 312,390 | 312,390 | [
"html",
"css"
] |
4,445,346 | 1 | 4,445,358 | null | 0 | 2,808 | i use windows xp , so i cant create a `'.htaccess'` file, and then update it to django hosting .
so i have to create it using ssh , i use `SecureCRT 6.5`:

i know `cd` , `dir` , `mkdir` , but i dont know how to create a file , and write some word in it ?
thanks
this is the photo i use `nano` on windows xp :

what should i do next ?
| how to create a '.htaccess' file using ssh | CC BY-SA 2.5 | null | 2010-12-14T23:30:11.680 | 2010-12-14T23:51:39.860 | 2010-12-14T23:51:39.860 | 420,840 | 420,840 | [
"python",
"django",
"ssh"
] |
4,445,372 | 1 | 4,445,777 | null | 1 | 187 | I'm hosting an appengine app and have found that the biggest part of my costs is my CPU usage so I'm trying to reduce that. I'm trying to find where I can make the biggest gains from optimization, however, the dashboard on my app lists a bunch of URL's and their associated CPU usage. How come this doesn't add to 100%?

| Why does appengine cpu usage not add to 100%? | CC BY-SA 2.5 | null | 2010-12-14T23:35:07.510 | 2010-12-15T00:52:27.213 | null | null | 125,429 | [
"google-app-engine",
"cpu-usage"
] |
4,445,400 | 1 | null | null | 0 | 108 | I came across this tender notice for Web Site Development and Site Support in The Daily Express dated December 13, 2010. I was wondering why interested web developers have to pay so much money (US$300) just to submit a bid? (why should we have to pay anything at all, coming to think of it). Is it to attract serious bidders only, or to make money
| Web Site Development & Site Support Tender - | CC BY-SA 2.5 | null | 2010-12-14T23:39:39.980 | 2010-12-15T00:53:40.290 | null | null | 225,998 | [
"bids"
] |
4,445,583 | 1 | 4,445,618 | null | 4 | 7,280 | While using NotePad++, and select a certain word, it automatically highlights all matched words?

Does anyone know if there is a Visual Studio addin that can do this? or are there any hidden environment setting that can do this?
| Visual Studio addin; to highlight all words which match selected word? | CC BY-SA 2.5 | null | 2010-12-15T00:14:56.467 | 2012-05-17T10:56:13.393 | 2010-12-15T00:36:06.443 | 14,118 | 14,118 | [
"visual-studio",
"add-in",
"syntax-highlighting",
"visual-studio-addins"
] |
4,445,948 | 1 | 4,445,963 | null | 4 | 5,296 | Could someone explain exercise 27 of learn python the hard way to me?
Here is an image showing the section i don't understand.

Is it saying that assuming the left column of the table is true, is the answer true?
eg if x = y is not false, is x=y true? yes.
but then.. if x = y is false and true, is x=y true? no??
| Understanding logic in python (Exercise 27 of Learn Python the Hard Way) | CC BY-SA 2.5 | 0 | 2010-12-15T01:29:18.040 | 2014-11-14T09:19:25.637 | 2010-12-15T03:24:22.620 | 397,649 | 397,649 | [
"python",
"logic"
] |
4,446,416 | 1 | 4,458,739 | null | 3 | 1,609 | I can't run any tess in VS2010. Even tests that have run before. I remember setting some services to manual start a few weeks ago, but can't remember what!
Edit: Even after uninstalling and reinstalling Studio2010 (and taking off the Novell Netware Client which I though may be an issue) it still doesn't work.

| VS2010 Test Runner - Unable to start agent process | CC BY-SA 2.5 | null | 2010-12-15T03:25:11.530 | 2017-05-24T18:27:15.097 | 2010-12-15T19:32:24.187 | 26,086 | 26,086 | [
"visual-studio-2010",
"mstest"
] |
4,446,564 | 1 | null | null | 1 | 315 | I'm using Windows 7 and getting the following error. This was not when I was using Windows XP.

| HTTP Error 500.19 - Internal Server Error | CC BY-SA 2.5 | null | 2010-12-15T04:03:54.947 | 2010-12-15T04:16:53.953 | 2010-12-15T04:09:28.903 | 231,179 | 231,179 | [
"asp.net",
"internal"
] |
4,446,878 | 1 | 4,447,132 | null | 8 | 6,698 | Several apps, including the built-in Address Book use a HUD window that is semi-transparent, with large shadowed text. I'd like to implement a similar window in my Cocoa Mac app.

Is there a free implementation of this kind of window somewhere?
If not, what is the best way to implement it?
| How to implement HUD-style window like Address Book's "Show in Large Type" | CC BY-SA 2.5 | 0 | 2010-12-15T05:05:26.333 | 2013-10-10T20:04:42.827 | 2010-12-15T17:59:30.293 | 4,468 | 4,468 | [
"cocoa",
"macos",
"hud"
] |
4,446,927 | 1 | 4,446,940 | null | 7 | 238 | In the [Kohana code conventions](http://kohanaframework.org/guide/about.conventions) it states that using `&&` and `||` is "incorrect":

Is there any advantage to using `AND` and `OR` other than clarity?
| Is there any advantage to using AND and OR over && and || in PHP? | CC BY-SA 2.5 | null | 2010-12-15T05:16:28.103 | 2010-12-15T06:17:21.800 | null | null | 4,639 | [
"php",
"naming-conventions"
] |
4,447,344 | 1 | 4,447,355 | null | 0 | 808 | I am getting problem in alignment of element that is in FooterTemplate of GridView.
Anyone suggest me how to do it.The Code is:
```
<asp:GridView ID="gvComment" runat="server" AutoGenerateColumns="false"
OnRowDataBound="gvComment_RowDataBound" OnRowCreated="gvComment_RowCreated" Width="100%" ShowHeader="false" BorderWidth="0px" ShowFooter="true">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<table border="0" cellpadding="0" cellspacing="0" width="100%" >
<tr>
<td valign="middle" align="left" style="width:10%"><img id="imgUser" src="" alt="" title="" runat="server" /></td>
<td align="left" valign="top">
comment comment
<asp:Label ID="lblNameComments" runat="server" Visible="false" ></asp:Label>
</td>
</tr>
<tr><td colspan="2" style="height:7px;"></td></tr>
<tr>
<td colspan="2" style="padding-top:10px;background-image:url(../Images/dotted_line.jpg);background-repeat:repeat-x;background-position:center;"></td>
</tr>
<tr><td colspan="2" style="height:7px;"></td></tr>
</table>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField>
<FooterTemplate >
<table border="0" cellpadding="0" cellspacing="0" width="100%" >
<tr>
<td align="left">
Footer Text
Footer Text
Footer Text
</td>
</tr>
</table>
</FooterTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
```
I have set align property of td left but it doesn't work.Page output shown in image.

| How to left align footer element | CC BY-SA 2.5 | null | 2010-12-15T06:35:26.517 | 2011-11-24T02:37:38.323 | 2011-11-24T02:37:38.323 | 3,043 | 503,125 | [
"asp.net",
"gridview"
] |
4,447,595 | 1 | 4,447,829 | null | 1 | 957 | I have an input running in an HTML page. I'm using jQuery UI.I want the user to type some text in the input, and then once he will press Enter, the input will become empty and the text he had entered will appear bellow, with an X next to it. This will allow the user to enter many options, and then remove any of them by clicking on the respective X button. I'm attaching an illustration of what I want to achieve:

Is there a jQuery UI control that can help me achieve this? If not, how else would you do it?
Thanks!
| Multiple selection control jQuery UI | CC BY-SA 2.5 | null | 2010-12-15T07:18:54.160 | 2010-12-15T07:55:48.037 | null | null | 539,451 | [
"jquery",
"selection"
] |
4,447,970 | 1 | null | null | 0 | 117 | ```
SELECT
ISNULL(CONVERT(CHAR(8), A.field1), REPLICATE(' ', 8)) +
ISNULL(CONVERT(CHAR(10), A.field2), REPLICATE(' ', 10))
from #tmpTable a
```
I have to concat some field. Field1 and Field2 are integer, when I convert to char, they must have
a specific size. If the value of field1 is 123 the result must be '123 ' (with the blank).
At the end I want something like this :
```
123 456
985454 232355
```
If the value is null, I have an empty space of 8 or 10 blank
Any idea ?
Thanks,
Update1:
The result I need is
```
1001335
1001335
12401886 10994
```

| Conversion to char but complet with blank | CC BY-SA 2.5 | null | 2010-12-15T08:20:40.293 | 2010-12-15T09:01:23.643 | 2010-12-15T08:53:39.330 | 118,584 | 118,584 | [
"sql",
"sql-server",
"tsql"
] |
4,447,987 | 1 | 4,449,779 | null | 13 | 3,376 | So Im a source control idiot so please humor me with this checklist.
I finally decided to use Mercurial + TortoiseHg + (VS2010 + [HgSccPackage](http://bitbucket.org/zzsergant/hgsccpackage/wiki/Home)) + Kiln for my next project.
I read [http://hginit.com/](http://hginit.com/) and I played around quite a bit, but I don't know much about source control so I don't want to make a mistake here, my current project is my biggest and most valuable one yet.
So here is my checklist:
:
1. I create a new repo in kiln online.
2. Then clone it on my pc.
3. I copy my entire project folder (Solution with mutiple projects under that folder) into the repo.
4. I add this content into a .hgignore file in the repo root.
5. From TortoiseHg I click add files
6. I occasionally commit from VS.
7. When I'm good and ready I go Sync->Push (So this is all good right?)
One I had here is. I can't find Add Files equivalent in HgScc, I noticed when I added a new files from the VS-IDE, it doesn't have the icon for source control. (Its not added to mercurial?)
So I ended up adding files through the IDE and they didn't have a check. Then after a few commits (and other things I don't remember) I noticed there was an extra branch or something:

And now If I go try to push I get `"(did you forget to merge? use push -f to force)"`. (And yes I hit incoming and I have NO in coming changes)
Anyway,
So Im a little confused about named branching, but Kiln as their own branch/clone thingy. I [read instructions here](http://kiln.stackexchange.com/questions/372/kiln-branch-and-merge-how-to)
1. So, Online, I have option that create a "Branch" in Kiln online.
2. Then I will clone this as a new repo locally (as if it were a new repo)
3. I will make my changes, commit, push.
4. Then I'll pull from the MAIN repo and push from my branch repo to the MAIN.
So I'm not really seeing any merge option here, Im guessing mercurial handles the merging on its own? So I'm not seeing the branch from the repository explorer? Is this how its supposed to be done?
Last question, what is the difference between the View History and View Change Log options and what hg options do they correspond to?:

---
: Forgot to mention I'm the only lonely developer on this project. =P
| idiots checklist for mercurial with visual studio 2010 | CC BY-SA 2.5 | 0 | 2010-12-15T08:23:13.053 | 2010-12-18T06:46:15.313 | 2017-05-23T10:29:40.617 | -1 | 368,070 | [
"visual-studio-2010",
"mercurial",
"tortoisehg",
"kiln"
] |
4,448,274 | 1 | 5,744,019 | null | 0 | 1,874 | I am trying to load URL inside a WebViewClient as below:
```
webview.setWebViewClient(new WebViewClient()
{
public boolean shouldOverrideUrlLoading(WebView view, String url) {
view.loadUrl(url);
return true;
}
public void onPageFinished(WebView view, String url)
{
}
public void onReceivedError(WebView view, int errorCode, String description, String failingUrl)
{
}
});
webview.loadUrl(articleLink);
```
## Problem:
Web URL is loading successfully but in some occurrence i got the following errors, at the same time i would like to display Alert Dialog instead of Webview with Error message.
So can you please let me know ,
1. "Web page not available" error
2. "Directory listing Denied"
I have attached the 2nd one's image for your reference:

| Android - WebViewClient | CC BY-SA 2.5 | null | 2010-12-15T09:07:53.000 | 2011-04-21T12:21:20.250 | null | null | 379,693 | [
"android"
] |
4,448,329 | 1 | 4,448,761 | null | 7 | 6,918 | The `UIPickerView` that appears in Safari has a check mark beside the current choice. Is there a built-in way to get this, or do I have to program it up myself? If I do have to create it, can anyone point me to some code to do this? Thanks
| How can I get a check mark beside UIPickerView labels? | CC BY-SA 2.5 | 0 | 2010-12-15T09:14:53.097 | 2010-12-15T10:28:16.810 | null | null | 74,118 | [
"iphone",
"cocoa-touch",
"uipickerview"
] |
4,449,064 | 1 | 4,535,356 | null | 1 | 946 | i am new to zend framework. i am trying to create a zend framework project in netbeans 6.9. but the ide shows some error, i couldn't understand. the following are the screenshots that could illustrate my problem.







the following are the error message shown in the ide log:
***************************** ZF ERROR ********************************
In order to run the zf command, you need to ensure that Zend Framework
is inside your include_path. There are a variety of ways that you can
ensure that this zf command line tool knows where the Zend Framework
library is on your system, but not all of them can be described here.
The easiest way to get the zf command running is to give it the include
path via an environment variable ZEND_TOOL_INCLUDE_PATH or
ZEND_TOOL_INCLUDE_PATH_PREPEND with the proper include path to use,
then run the command "zf --setup". This command is designed to create
a storage location for your user, as well as create the zf.ini file
that the zf command will consult in order to run properly on your
system.
Example you would run:
$ ZEND_TOOL_INCLUDE_PATH=/path/to/library zf --setup
Your are encourged to read more in the link that follows.
Zend_Tool & CLI Setup Information
(available via the command line "zf --info")
* Home directory found in environment variable HOMEPATH with value \Documents and Settings\oandz
* Storage directory assumed in home directory at location \Documents and Settings\oandz/.zf/
* Storage directory does not exist at \Documents and Settings\oandz/.zf/
* Config file assumed in home directory at location \Documents and Settings\oandz/.zf.ini
* Config file does not exist at \Documents and Settings\oandz/.zf.ini
To change the setup of this tool, run: "zf --setup"
> > can any one give the procedure to set-up zend framework and to configure it with netbeans 6.9 starting from scratch.
thanks in advance.
| trouble configuring zend framework with netbeans 6.9! | CC BY-SA 2.5 | null | 2010-12-15T10:47:02.443 | 2011-01-24T00:01:37.687 | null | null | 407,418 | [
"zend-framework",
"netbeans",
"netbeans-6.9"
] |
4,449,520 | 1 | 4,450,777 | null | 4 | 293 | When I open a file with vim or gvim from console on windows that is located in a sub directory (e.g. `gvim subdir/file`), it creates a new file at `subdir\subdir\file` saying `"subdir\file" [New DIRECTORY]` instead of simply opening the existing file at `subdir\file`.

This happens since I added the following line to my vimrc:
```
set enc=utf-8
```
Is there a possibility to open and create files in UTF-8 mode on Windows without this issue?
You may also look at [my vimrc file](https://gist.github.com/741879).
Thank you for any help.
| Vim opens a new folder instead of an existing file with `set enc=utf-8` enabled | CC BY-SA 2.5 | 0 | 2010-12-15T11:44:49.763 | 2010-12-15T14:19:35.243 | null | null | 432,354 | [
"windows",
"utf-8",
"vim"
] |
4,451,183 | 1 | null | null | 8 | 3,864 | We have which does not show the individual lines on which search results occur as do all other installations, as shown here:

| Why would eclipse not show search results inside file in results list? | CC BY-SA 2.5 | 0 | 2010-12-15T14:52:14.227 | 2018-10-05T10:30:36.617 | 2010-12-16T10:24:27.747 | 4,639 | 4,639 | [
"eclipse",
"search"
] |
4,451,204 | 1 | 4,451,750 | null | 8 | 4,186 | Can someone much brighter than I succinctly describe to the SO community the NFA to DFA conversion algorithm? (Preferably in 500 words or less.) I've seen diagrams and lectures that have only served to confuse what I thought I once knew. I'm mostly confident in generating an initial NFA transition table from a state diagram, but after that, I lose the DFA in the epsilons and subsets.
1) In a transition (delta) table, which column represents the new DFA states? Is it the first column of generated states?
2) In row {2,3}, col 0 of my example below, what does the {2,3} mean about the NFA in terms of its state diagram? (Sorry, I must think in pictures.) And I assume it will be a "loop-back on input 0" in the DFA?
3) Any simple "rules of thumb" on getting from the table to the DFA or on recognizing the accept states of the resulting DFA?
Finitely Autonomous
```
delta | 0 | 1 |
=======+=======+========+
{1} |{1} |{2} |
{2} |{3} |{2,3} |
{3} |{2} |{2,4} |
{2,3} |{2,3} |{2,3,4} |
{2,4} |{3,4} |{2,3,4} |
{2,3,4}|{2,3,4}|{2,3,4} |
{3,4} |{2,4} |{2,4} |
```
---
Edit: Here is the above table in [dot format](http://www.graphviz.org/content/dot-language), cheers Regexident.
```
digraph dfa {
rankdir = LR;
size = "8,5"
/* node [shape = doublecircle]; "1";*/
node [shape = circle];
"1" -> "1" [ label = "0" ];
"1" -> "2" [ label = "1" ];
"2" -> "3" [ label = "0" ];
"2" -> "2_3" [ label = "1" ];
"3" -> "2" [ label = "0" ];
"3" -> "2_4" [ label = "1" ];
"2_3" -> "2_3" [ label = "0" ];
"2_3" -> "2_3_4" [ label = "1" ];
"2_4" -> "2_3" [ label = "0" ];
"2_4" -> "2_3_4" [ label = "1" ];
"2_3_4" -> "2_3_4" [ label = "0" ];
"2_3_4" -> "2_3_4" [ label = "1" ];
"3_4" -> "2_4" [ label = "0" ];
"3_4" -> "2_4" [ label = "1" ];
}
```
And here in rendered form:

The table lacks any information regarding state acceptance, hence so does the graph.
| A succinct description of NFA to DFA conversion? | CC BY-SA 3.0 | 0 | 2010-12-15T14:53:48.900 | 2020-09-28T15:11:46.220 | 2013-06-20T11:15:58.187 | 227,536 | 205,926 | [
"algorithm",
"finite-automata",
"dfa",
"nfa"
] |
4,451,212 | 1 | null | null | 6 | 307 | Trying to resize images stored on my sdcard, I noticed that original colors where altered. It seams that BitmapFactory.decodeFile is responsable for this. Here is a demonstration code:
```
private void testImage() throws Exception{
BitmapFactory.Options o = new BitmapFactory.Options();
o.inDither = false;
o.inPreferredConfig = Bitmap.Config.ARGB_8888;
o.inScaled = false;
Bitmap b = BitmapFactory.decodeFile("/sdcard/test/original.jpg", o);
b.compress(Bitmap.CompressFormat.JPEG, 100, new FileOutputStream("/sdcard/test/result.jpg"));
b.compress(Bitmap.CompressFormat.PNG, 100, new FileOutputStream("/sdcard/test/result.png"));
}
```
Resulting images (original.jpg, result.jpg, result.png):

Has you can see, the skin of the boy is a bit green on the 2 resulting images. Any tips to solve this issue ?
| Android has no respect for colors! | CC BY-SA 2.5 | 0 | 2010-12-15T14:54:40.430 | 2010-12-15T15:17:09.250 | 2010-12-15T15:13:08.687 | 508,194 | 508,194 | [
"android",
"bitmap"
] |
4,451,839 | 1 | 4,452,737 | null | 9 | 4,584 | I use the code below to render a transparent icon:
```
private void button1_Click(object sender, EventArgs e)
{
// using LoadCursorFromFile from user32.dll
var cursor = NativeMethods.LoadCustomCursor(@"d:\Temp\Cursors\Cursors\aero_busy.ani");
// cursor -> bitmap
Bitmap bitmap = new Bitmap(48, 48, PixelFormat.Format32bppArgb);
Graphics gBitmap = Graphics.FromImage(bitmap);
cursor.DrawStretched(gBitmap, new Rectangle(0, 0, 32, 32));
// 1. Draw bitmap on a form canvas
Graphics gForm = Graphics.FromHwnd(this.Handle);
gForm.DrawImage(bitmap, 50, 50);
// 2. Draw cursor directly to a form canvas
cursor.Draw(gForm, new Rectangle(100, 50, 32, 32));
cursor.Dispose();
}
```
Unfortunately I am unable to render a transparent Cursor to Bitmap! It works when I draw Cursor directly to the form canvas, but there is a problem when I draw Cursor to bitmap.
Any advice is highly appreciated.

| How to Render a Transparent Cursor to Bitmap preserving alpha channel? | CC BY-SA 2.5 | 0 | 2010-12-15T15:45:15.033 | 2021-12-28T15:45:57.607 | 2021-12-28T15:45:57.607 | 4,294,399 | 188,516 | [
"c#",
".net",
"transparency",
"gdi+",
"mouse-cursor"
] |
4,451,943 | 1 | 4,454,079 | null | 1 | 3,527 | I'm trying my very best to edit the Magento design the way they want you to (using a local.xml rather than editing the page.xml) but this system is so horrible and convoluted, it's proving to be seriously tricky to do so.
The problem I have now is that I can't seem to move the "top.links" block into another block in the header. At the moment in page.xml this block is within the header block. I've tried absolutely everything in my local.xml to get this to work, I've tried the following edits.
```
<layout version="0.1.0">
<default>
<!-- Here is where we edit the header block -->
<reference name="header">
<remove name="top.links" />
<remove name="top.search" />
<!-- This is the block that holds the HUD -->
<block type="page/html" name="hud" as="hud" template="page/html/hud.phtml">
<block type="page/template_links" name="top.links" as="topLinks" />
</block>
</reference>
</default>
</layout>
```

Note that the links should be inside the brown box (this is the HUD block).
```
<layout version="0.1.0">
<default>
<!-- Here is where we edit the header block -->
<reference name="header">
<remove name="top.search" />
<!-- This is the block that holds the HUD -->
<block type="page/html" name="hud" as="hud" template="page/html/hud.phtml">
<block type="page/template_links" name="top.links" as="topLinks" />
</block>
</reference>
</default>
</layout>
```

```
<layout version="0.1.0">
<default>
<!-- Here is where we edit the header block -->
<reference name="header">
<remove name="top.links" />
<remove name="top.search" />
<!-- This is the block that holds the HUD -->
<block type="page/html" name="hud" as="hud" template="page/html/hud.phtml">
<block type="page/template_links" name="hud.links" as="hudLinks" template="page/template/hudLinks.phtml"/>
</block>
</reference>
</default>
</layout>
```
Below is hud.phtml
```
<!-- hud.phtml -->
<div id="hud">
<h3>Welcome</h3>
<?php echo $this->getChildHtml('hudLinks') ?>
<?php echo $this->getChildHtml('top.search') ?>
</div>
```
This brings the most interesting results. I can see the template is found but nothing appears.

I really am clueless with this. Am I doing something completely wrong here? For what it's worth, here is the code I'm using for hudLinks.phtml and the top.links template.
```
<?php $_links = $this->getLinks(); ?>
<?php if(count($_links)>0): ?>
<ul class="links"<?php if($this->getName()): ?> id="<?php echo $this->getName() ?>"<?php endif;?>>
<?php foreach($_links as $_link): ?>
<li<?php if($_link->getIsFirst()||$_link->getIsLast()): ?> class="<?php if($_link->getIsFirst()): ?>first<?php endif; ?><?php if($_link->getIsLast()): ?> last<?php endif; ?>"<?php endif; ?> <?php echo $_link->getLiParams() ?>><?php echo $_link->getBeforeText() ?><a href="<?php echo $_link->getUrl() ?>" title="<?php echo $_link->getTitle() ?>" <?php echo $_link->getAParams() ?>><?php echo $_link->getLabel() ?></a><?php echo $_link->getAfterText() ?></li>
<?php endforeach; ?>
</ul>
<?php endif; ?>
```
| Can't move top.links (topLinks) block in Magento | CC BY-SA 2.5 | null | 2010-12-15T15:55:46.143 | 2010-12-15T19:38:57.070 | null | null | 218,224 | [
"layout",
"magento"
] |
4,452,241 | 1 | 4,528,660 | null | 3 | 5,229 | How Guys
I'm working on a project that need display same thing like this, I think it make sense to use some tools to automatically generate the thumbnails and save them in the database when I submit a video
I'm also want some similar rails code that do the youtube alike function, could anyone give me suggestion rails code website.
Thanks

| Can rails generate a thumbnail picture of a video? | CC BY-SA 2.5 | 0 | 2010-12-15T16:23:54.000 | 2013-06-15T00:34:51.647 | null | null | 456,218 | [
"video"
] |
4,452,271 | 1 | 4,452,456 | null | 4 | 829 | As part of a build I am copying files to a user specified folder.. Right now I am doing it like this:
```
<input message="Select Drive to Install Trainer"
addproperty="trainer.drive" validargs="c:/,d:/,q:/,z:/" />
<input message="Enter Directory to Install Trainer"
addproperty="trainer.user.dir"/>
<property name="trainer.dir" value="${trainer.drive}${trainer.user.dir}"/>
```
So a user selects the drive letter, then enters the path to the folder like: "workspaces/myworkspace"
Which sets the trainer.dir to: "c:/workspaces/myworkspace"
Is there a better way to do this?
For instance, is there a way to bring up a dialog like this in ant?

| Folder selection in Ant | CC BY-SA 2.5 | 0 | 2010-12-15T16:26:18.257 | 2010-12-15T19:18:08.973 | 2010-12-15T19:18:08.973 | 33,863 | 33,863 | [
"java",
"ant",
"directory",
"jfilechooser"
] |
4,452,415 | 1 | null | null | 3 | 329 | I have an annoying problem with Visual Studio highlighting. I installed my favourite colourscheme ([zenburn 2010](http://studiostyl.es/schemes/zenburn-2010)), and I have found that when I'm in debug mode, this will happen when my application is paused:

I have run through the hundred or so colours in the settings window, but I am unable to locate the setting that will affect this background colour. It's not exactly a show-stopper, but I'd still really like to know how to solve this.
I have resharper installed in case that affects anything. I can't see how it would though.
| What is the name of this colour scheme element? | CC BY-SA 2.5 | 0 | 2010-12-15T16:37:13.797 | 2012-07-20T21:20:10.430 | 2011-08-08T12:40:34.213 | 856,132 | 430,634 | [
"visual-studio",
"visual-studio-2010",
"color-scheme"
] |
4,452,762 | 1 | 4,461,168 | null | 2 | 2,225 | I have an orchestration map that maps two source messages into one destination message. When the schema for one of the source messages changes, I was hoping to be able to click on the input message part and select "Replace Schema" to refresh the schema for just the message part affected. Instead I can only replace the entire multipart message schema with the single message part schema.

My only other option seems to be to generate a new map from the orchestration transform shape, but this means I have to recreate all the links in my map...
Does anyone know of a more efficient way to update this type of schema?
| How to replace a multipart message schema in a map without replacing the map | CC BY-SA 2.5 | null | 2010-12-15T17:09:47.520 | 2011-01-15T15:43:23.153 | null | null | 321,396 | [
"biztalk",
"biztalk-2009",
"biztalk-mapper"
] |
4,452,815 | 1 | 4,453,034 | null | 4 | 15,983 | I need to be able to create a WAV file using the mic in Android. Currently, I'm having a lot of trouble. So far, this is my situation. I'm using parts of the micDroid project code to record thus:
```
//read thread
int sampleRate = 44100;
int bufferSize = AudioRecord.getMinBufferSize(sampleRate,android.media.AudioFormat.CHANNEL_CONFIGURATION_MONO,android.media.AudioFormat.ENCODING_PCM_16BIT);
AudioRecord ar = new AudioRecord(AudioSource.MIC,sampleRate,android.media.AudioFormat.CHANNEL_CONFIGURATION_MONO,android.media.AudioFormat.ENCODING_PCM_16BIT,bufferSize);
short[] buffer = new short[bufferSize];
ar.startRecording();
while(isRunning){
try{
int numSamples = ar.read(buffer, 0, buffer.length);
queue.put(new Sample(buffer, numSamples));
} catch (InterruptedException e){
e.printStackTrace();
}
}
//write thread
int sampleRate = 44100;
WaveWriter writer = new WaveWriter("/sdcard","recOut.wav",sampleRate,android.media.AudioFormat.CHANNEL_CONFIGURATION_MONO,android.media.AudioFormat.ENCODING_PCM_16BIT);
try {
writer.createWaveFile();
} catch (IOException e) {
e.printStackTrace();
}
while(isRunning){
try {
Sample sample = queue.take();
writer.write(sample.buffer, sample.bufferSize);
} catch (IOException e) {
//snip
}
}
```
Which appears to work fine, however the end result recognizably contains whatever I said, but it is horribly distorted. Here's a screen cap of audacity (WMP refuses to play the file).

Any help would be greatly appreciated, let me know if you need more code / info.
Following markus's suggestions, here is my updated code:
```
int sampleRate = 16000;
writer = new WaveWriter("/sdcard","recOut.wav",sampleRate,android.media.AudioFormat.CHANNEL_IN_MONO,android.media.AudioFormat.ENCODING_PCM_16BIT);
int bufferSize = AudioRecord.getMinBufferSize(sampleRate,android.media.AudioFormat.CHANNEL_IN_MONO,android.media.AudioFormat.ENCODING_PCM_16BIT);
AudioRecord ar = new AudioRecord(AudioSource.MIC,sampleRate,android.media.AudioFormat.CHANNEL_IN_MONO,android.media.AudioFormat.ENCODING_PCM_16BIT,bufferSize);
byte[] buffer = new byte[bufferSize]; //all references changed from short to byte type
```
...and another audacity screencap:

| Recording a wav file from the mic in Android - problems | CC BY-SA 2.5 | 0 | 2010-12-15T17:14:54.570 | 2014-02-16T22:55:26.157 | 2010-12-15T18:31:48.940 | 319,618 | 319,618 | [
"java",
"android",
"wav",
"audio-recording"
] |
4,453,116 | 1 | 4,485,304 | null | 1 | 6,592 | I'm using a custom view which has a background picture and is used to draw stuff on it.
This view is ignoring and , it is not wrapping the background picture and is stretching and pushing the controls under the view out of the screen.
The custom view is in main LinearLayout, but where ever I put it, it behaves the same way.
I tried with , but physical size is somehow still the same under visible controls and the size is important because of the coordinates I save for other times. It is even present under the custom title, and coordinates are returned as negatives and thats also a problem.
I don't like the idea of statically setting the size because of different screen sizes.
```
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<org.danizmax.tradar.MapView
android:id="@+id/mapView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
/>
<!-- koordinate -->
<LinearLayout android:id="@+id/controls"
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:paddingLeft="10sp"
android:paddingRight="10sp">
<TextView android:id="@+id/coordsText"
android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:textStyle="bold"
android:textSize="15sp"
android:gravity="center"
android:layout_weight="1">
</TextView>
</LinearLayout>
<!-- radij -->
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingBottom="10sp"
android:paddingLeft="-5sp"
android:paddingRight="-5sp">
<Button android:text=""
android:id="@+id/ButtonInc"
android:background="@drawable/leftbuttonani"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1">
</Button>
<TextView android:id="@+id/radiusSize"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:textStyle="bold"
android:textSize="16sp"
android:gravity="center"
android:layout_weight="1"
android:paddingLeft="0sp"
android:paddingRight="0sp">
</TextView>
<Button android:text=""
android:id="@+id/ButtonDec"
android:background="@drawable/rightbuttonani"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1">
</Button>
</LinearLayout>
<!-- alert togle -->
<LinearLayout
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:paddingLeft="-5sp"
android:paddingRight="-5sp">
<Button android:text=""
android:id="@+id/ButtonDec"
android:background="@drawable/buttonani"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1">
</Button>
<ToggleButton
android:id="@+id/toggleAlert"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textColor="#D8D8D8"
android:background="@drawable/buttonani"
android:textOn="@string/alertOn"
android:textOff="@string/alertOff"
android:textStyle="bold"
android:layout_weight="0.5"
android:paddingTop="1sp">
</ToggleButton>
<Button android:text=""
android:id="@+id/ButtonDec"
android:background="@drawable/buttonani"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_weight="1">
</Button>
</LinearLayout>
<!-- izpis zadnjega dogodka -->
<TextView android:id="@+id/timeStatText"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textStyle="bold"
android:textSize="10sp"
android:gravity="center">
</TextView>
```
This is how it should look, the blue part is :

any idea?
| Android custom view is ignoring layout params im xml completely, and is stretching over the whole screen | CC BY-SA 2.5 | 0 | 2010-12-15T17:43:51.657 | 2010-12-19T21:47:33.043 | 2010-12-15T18:16:22.770 | 491,320 | 491,320 | [
"android",
"view",
"android-layout"
] |
4,453,175 | 1 | 4,454,292 | null | 53 | 58,078 | I have 2 `TextBox`es in my wpf app, one for user name and other for password, both have `FontSize=20`, but the text appears like this:

How can I fix this?
Xaml:
```
<TextBox Grid.Row="1" Grid.Column="1" Height="40" BorderThickness="1" BorderBrush="#FFD5D5D5" FontSize="36" Text="test" />
<PasswordBox Grid.Row="3" Grid.Column="1" Height="40" BorderThickness="1" BorderBrush="#FFD5D5D5" FontSize="36" Password="test" />
```
| Vertical Align in WPF TextBox | CC BY-SA 3.0 | 0 | 2010-12-15T17:50:28.680 | 2022-05-16T01:40:09.603 | 2013-07-07T16:28:59.847 | 305,637 | 298,834 | [
"wpf",
"textbox",
"font-size"
] |
4,453,344 | 1 | 4,478,376 | null | 6 | 731 | In iTunes, you can see the charge status of the iPhone currently connected:

This updates as the phone charges, and even shows when the phone is done charging.
Is there a way I can discover the charge status programmatically from the Mac? Any programming language or API is fine.
| How do you get the charge status of a connected iPhone from the Mac? | CC BY-SA 2.5 | 0 | 2010-12-15T18:10:03.560 | 2013-05-30T15:00:38.263 | 2010-12-22T20:09:00.043 | 28,768 | 140 | [
"iphone",
"macos",
"itunes",
"command-line-interface"
] |
4,453,418 | 1 | 4,453,478 | null | 1 | 2,227 | I used to build my projects with maven. Now I want to do it 'manually'. But I struggle a little bit with directory order and other stuff. I first just created a new dynamic web project in eclipse and added JSF libraries. Now I tried to deploy a hello world page onto a tomcat 7. But jsf-tags are not getting rendered.
Here is my directory structure:

Anybody has an idea where the mistake is? Am I missing a library or is my structure wrong?
cheers
---
It finally works! thank's to balusc
| Setting up a JSF project without maven | CC BY-SA 2.5 | null | 2010-12-15T18:18:31.713 | 2010-12-15T19:52:56.153 | 2010-12-15T19:52:56.153 | 389,430 | 389,430 | [
"java",
"jsf",
"jsf-2"
] |
4,453,639 | 1 | 4,455,599 | null | 7 | 5,322 | Is there any way to print the figure to the clipboard so that the quality is identical to what the `Edit-->Copy Figure` option provides?
I used to save the figure to powerpoint file by using saveppt.m obtained from [Matlab Central](http://www.mathworks.com/matlabcentral/fileexchange/340). It worked well until yesterday. I noticed that the stored image quality was somehow degraded. I tried to re-generate some ppt slides with exactly the same script and the same source data, but the new slides are simply of worse quality.
I investigated into this problem a little bit and discovered that when the figure is copied to clipboard by running `print -dmeta`, the image in the clipboard is already degraded, while if I use the `Edit-->Copy Figure` option in the figure window, I get the image as clear as the original image in the figure window.
Following is an example for your reference. I copied the image from a figure to the clipboard by two different methods, and paste it to Microsoft Paint program, and cut a piece of it to show below:
The image using `print -dmeta`: 
The image using `Edit-->Copy Figure`: 
If you compare the Xtick label '50', you may see that the image from `Edit-->Copy Figure` is smoother.
At the beginning I thought it was a problem of the resolution, but setting `-rN` to change the resolution does not seem to resolve my problem, at least not for N<=300.
Thank you for your help.
| How to print figure to clipboard by PRINT function with the quality identical to 'Edit-->Copy Figure' option? | CC BY-SA 2.5 | 0 | 2010-12-15T18:46:10.213 | 2010-12-15T22:26:38.930 | 2010-12-15T19:24:23.470 | 295,845 | 295,845 | [
"matlab",
"figure"
] |
4,453,791 | 1 | 4,453,944 | null | 0 | 283 | I need to display a NSNumberField that only accepts numbers. Is there some Cocoa-touch equivalent of NSNumberFormatter? If yes, how do I access it (see screenshot below)?

| NSNumberFormatter for Cocoa-touch? | CC BY-SA 2.5 | 0 | 2010-12-15T19:05:22.897 | 2010-12-15T19:37:04.747 | 2010-12-15T19:37:04.747 | 74,415 | 74,415 | [
"objective-c",
"cocoa",
"cocoa-touch",
"ios"
] |
4,453,900 | 1 | 4,454,324 | null | 3 | 1,890 | I can't seem to figure out what is meant by this symbol...

I checked here: [Egit User Guide "Icon Decorations"](http://wiki.eclipse.org/EGit/User_Guide#Icon_Decorations), and I don't see it.
When I do a status on my branch it says my working folder is clean.
I am using 0.9.3 version.
| Egit - exclamation point on folder | CC BY-SA 2.5 | null | 2010-12-15T19:17:00.480 | 2010-12-15T20:41:24.017 | 2010-12-15T20:41:24.017 | 6,309 | 112,665 | [
"git",
"egit"
] |
4,453,912 | 1 | 4,453,937 | null | 1 | 183 | For someone that is not used to mySQL, when using [phpMyAdmin](http://www.phpmyadmin.net/) administration program, what is the recommended setup to backup the entire database with all tables and with data?

| if we only have access to phpMyAdmin what's the best way to backup the entire db? | CC BY-SA 2.5 | null | 2010-12-15T19:18:37.210 | 2010-12-15T20:26:08.317 | null | null | 28,004 | [
"mysql",
"backup",
"phpmyadmin"
] |
4,454,409 | 1 | 4,457,827 | null | 4 | 5,121 | I've got a series of XY point pairs in MATLAB. These pairs describe points around a shape in an image; they're not a function, meaning that two or more y points may exist for each x value.
I can plot these points individually using something like
```
plot(B(:,1),B(:,2),'b+');
```
I can also use plot to connect the points:
```
plot(B(:,1),B(:,2),'r');
```
What I'm trying to retrieve are my own point values I can use to connect the points so that I can use them for further analysis. I don't want a fully connected graph and I need something data-based, not just the graphic that plot() produces. I'd love to just have plot() generate these points (as it seems to do behind the scenes), but I've tried using the linseries returned by plot() and it either doesn't work as I understand it or just doesn't give me what I want.
I'd think this was an interpolation problem, but the points don't comprise a function; they describe a shape. Essentially, all I need are the points that plot() seems to calculate; straight lines connecting a series of points. A curve would be a bonus and would save me grief downstream.
How can I do this in MATLAB?
Thanks!
Edit: Yes, a picture would help :)
The blue points are the actual point values (x,y), plotted using the first plot() call above. The red outline is the result of calling plot() using the second approach above. I'm trying to get the point data of the red outline; in other words, the points connecting the blue points.

| Getting intermediate points generated by plot() in MATLAB | CC BY-SA 2.5 | 0 | 2010-12-15T20:12:10.973 | 2017-03-15T15:00:32.937 | 2010-12-15T20:37:02.413 | 426,834 | 229,764 | [
"matlab",
"plot"
] |
4,454,652 | 1 | 4,454,870 | null | 0 | 647 | It should look like this - working on

but it is't showing like the above on :

Let me paste the codes I've been using :
```
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" >
<title>OrderBorder.com -- The way you want the deals for Apple mobile phones </title>
<link href="styles/main.css" type="text/css" rel="stylesheet"/>
<script src="scripts/jquery-1.4.4.min.js" type="text/javascript" language="javascript"></script>
<script src="scripts/cufon-yui.js" type="text/javascript" language="javascript"></script>
</head>
<body>
<div class="main">
<div class="header">
<div class="h-box-1 h-box-style">
<span class="ad-title">Enjoy Group Savings</span>
<div class="ad-content">
Wholesale prices for your Apple gear get lower with larger group size.
</div>
</div>
<div class="h-box-2 h-box-style">
<span class="ad-title">Earn Points</span>
<div class="ad-content">
Keep earning points with every purchase you and your friends make.
</div>
</div>
<div class="h-box-3 h-box-style">
<span class="ad-title">Reach Borderline Prices</span>
<div class="ad-content">
Eat my dust group!!! Use your points to bring your own prices to the border.
</div>
</div>
</div>
</div>
</body>
</html>
```
and
```
body
{
margin:0px;
background-image:url(../images/background.jpg);
}
div.main
{
background-image:url(../images/main_background.jpg);
background-repeat:no-repeat;
height:950px;
width:897px;
margin-right:auto;
margin-left:auto;
}
div.main div.header
{
width:893px;
height:120px;
margin-top:120px;
float:left;
}
div.main div.header div.h-box-style
{
width:100%;
height:100%;
}
div.main div.header div.h-box-style span.ad-title
{
color:Black;
font-family:Arial;
font-size:20px;
width:100%;
background-color:Red;
}
div.main div.header div.h-box-style div.ad-content
{
color:Gray;
font-family:Arial;
font-size:12px;
width:100%;
height:40px;
}
div.main div.header div.h-box-1
{
float:left;
width:220px;
height:80px;
margin-left:80px;
margin-top:20px;
}
div.main div.header div.h-box-2
{
float:left;
width:220px;
height:80px;
margin-left:70px;
margin-top:20px;
}
div.main div.header div.h-box-3
{
float:left;
width:250px;
height:80px;
margin-left:30px;
margin-top:20px;
}
```
When I inspect source code with Google Chrome developer tool, I can see that css is applied to the `.ad-title` and `ad-content` but these codes don't change anything.
So I've pasted everything I've done. can some one help me why Google Chrome behaves like that and doesn't show the text on the page under `.header'.
Thanks in advance.
| Google Chrome rendering problem whereas the code is working on IE | CC BY-SA 2.5 | null | 2010-12-15T20:40:45.613 | 2010-12-15T21:20:10.290 | 2010-12-15T20:47:27.987 | 44,852 | 44,852 | [
"html",
"css",
"internet-explorer",
"google-chrome"
] |
4,454,836 | 1 | 4,454,889 | null | 1 | 239 | I'm delving into XML and XSLT and am trying to generate a basic, tabular web page. The basic layout of the table seems to be ok, but I'm getting a column of " characters before I get my two-column table (which itself is in the second column of the web page). This is shown below:

There are exactly the number of " characters as there are elements of the XML file this is built from. The code that I think is causing the problem is listed below:
```
<tbody>
<xsl:for-each select="command">
<tr>
<td width="50%">
<xsl:value-of select="description"/>
</td>"
<td width="50%">
<xsl:value-of select="TLC"/>
</td>
</tr>
</xsl:for-each>
</tbody>
```
Is the character being generated in each `xsl:for-each select`? In the event that the above snippet of code looks good, I'll include the entirety of the XSLT file below. Feel free to let me know how dumpy my stuff looks, as I'm coming from a firmware and .NET background.
Thanks.
: Removed the full body of code since the answer, so obvious that I should smack myself, doesn't involve it.
| Extra characters in XSLT output | CC BY-SA 2.5 | null | 2010-12-15T21:01:36.023 | 2010-12-16T20:56:20.583 | 2010-12-16T20:56:20.583 | 416,190 | 416,190 | [
"xslt"
] |
4,455,277 | 1 | 4,455,895 | null | 1 | 4,423 | I create a GridPanel like this:
```
grid = new xg.GridPanel({
id: 'gridid',
store: store,
columns: [
...
```
Later on, I try to get the element so that I can load new data into it. In the Sencha Documentation it states that loadData is available to the GridPanel object

So I tried this:
```
Ext.getCmp('gridid').loadData(store);
```
And it chromes console prints this error:
```
Uncaught TypeError: Object [object Object] has no method 'loadData'
```
Interestingly, when I try
```
Ext.getCmp('gridid').getStore().loadData(store);
```
This error goes away and the current store disappears from the grid, but it remains empty, the new store isn't loaded. Please help!
UPDATE: When I console.log the store I see all the information inside the object as it should appear, but its not being rendered in the grid.
| Getting Component in ExtJS | CC BY-SA 2.5 | null | 2010-12-15T21:47:37.593 | 2010-12-15T23:08:15.963 | null | null | 242,934 | [
"extjs",
"grid"
] |
4,455,335 | 1 | 4,455,368 | null | 1 | 2,259 | here is my problem:
For example, lets say I have Chrome running with 5 tabs, this will create 6 processes called Chrome.exe, one for chrome and one each for the tabs.
Now using Process.GetProcessesByName("chrome") will return all 6 processes.
How can I work out which of the processes is the main one?
It is possible as this is what Process Explorer does:

Basically I want to get the handle for the master chrome process, how do I do this?
| C# Get Process Detailed Information | CC BY-SA 2.5 | null | 2010-12-15T21:54:21.230 | 2010-12-15T21:58:10.820 | null | null | 104,452 | [
"c#",
"process",
"monitoring",
"monitor"
] |
4,455,462 | 1 | 4,455,484 | null | 1 | 10,184 | ```
@font-face {
font-family:kai;
src: url(fonts/kai.ttf);
}
body {
font-family: kai, georgia, tahoma,verdana,serif;
}
```
I checked with this web site [http://www.webconfs.com/http-header-check.php](http://www.webconfs.com/http-header-check.php) 
Not quite sure it won't use this font?
How can I get it to use this particular font?
| Resource interpreted as font but transferred with MIME type text/html | CC BY-SA 3.0 | null | 2010-12-15T22:10:13.437 | 2012-05-06T01:56:35.827 | 2012-05-06T01:56:35.827 | 1,079,354 | 225,727 | [
"css",
"fonts"
] |
4,455,865 | 1 | 4,455,897 | null | 0 | 240 | In the screenshot below is an Entity (URL) in my model. The ParentId field is a self-referencing FK (points to Url.Id). You can see this navigation at the bottom of the screenshot.

In my SQL and my DB, which I generate the EDMX from, the self-referencing FK is called FK_Urls_Parent:
```
-- Creating foreign key on [ParentId] in table 'Urls'
ALTER TABLE [Urls]
ADD CONSTRAINT [FK_Urls_Parent]
FOREIGN KEY ([ParentId])
REFERENCES [Urls]
([Id])
ON DELETE NO ACTION ON UPDATE NO ACTION;
```
My questions are:
1. Why did EF generate Urls1 and Url1 just from that one FK? Url1 is a 0 or 1 property that is 'FromRole' Urls1. Urls1 is 'FromRole' Urls 'ToRole' Urls1. It seems like EF is making a navigation property that is the exact same as Url table. Why would it do this and can I do something to make it just generate the one, desired Navigation property: Urls1?
2. Okay, so not quite as important, but can I control the name of the Navigation property based on the FK name or something in the DB? I hate that it names it 'Url1'. I would prefer 'Parent', but don't want to have to manually change it in the designer every time I regenerate the model.
Thanks.
| Self-Referencing FK Generating Strangly | CC BY-SA 2.5 | null | 2010-12-15T23:04:20.170 | 2010-12-15T23:14:43.960 | null | null | 194,031 | [
"c#",
"sql",
"entity-framework",
"auto-generate"
] |
4,455,953 | 1 | null | null | 4 | 175 | I understand that there are several questions here about this problem, but I have a rather unique predicament. I'm working on a template that has to include certain tags, and has to work with other elements that are added to the template after I upload the code. I wouldn't worry about this, but I am having a time trying to get the footer to display at the bottom of the page. I can't alter anything about the footer, and it displays at the bottom of the div I'm using as a wrapper. The problem is if I set the height to a fixed value, there can only be so many comments made before the comment div overlaps the footer. I've tried several different solutions including setting the container div's height to auto, overflow to auto, bottom margin to 65 (height of the footer), and setting the overflow to scroll for the Comments div (resulted in very loose comments).
[Here is an example of the problem and the template as it stands.](http://www.drunkduck.com/AC_12_666_Sympathy_For_The_Devil/index.php?p=773469)
Here is the CSS styling for the container div (div id=Main)
```
#Main {
margin: 0px auto auto auto;
background-color: #808080;
font-family: Verdana, Geneva, Tahoma, sans-serif;
font-size: medium;
font-variant: normal;
color: #FFFFFF;
width: 900px;
position: relative;
}
```
Here's the CSS styling for the Comments div
```
#Comments {
background-color: #008080;
width: 450px;
height: auto;
top: 1750px;
left: 450px;
position: absolute;
overflow: auto;
}
```
And here's how the divs are stacked in the body
```
<div id="Main">
...
<div id="Comment_Form">
<!--[COMMENT_FORM=400,200]-->
</div>
<div id="Comments">
<!--[COMMENTS=400]-->
Comments
</div>
</div>
```
Since the page is going to be image heavy, I'm trying to keep the code lightweight (and probably failing at it pretty badly).
Thank you for your help and I'll post the template as of now if anyone needs it.
EDIT:
Okay, it's occurred to me that a) I need to redo the CSS and the divs that I have down, and b) I have no clue how to do it using pure CSS, or at least with out fighting it as one of you has said. What I'm trying to achieve is this:

I have no clue How to do this. and any help would be greatly appreciated (as well as any way to avoid having each and every element in its own div)
| How do I Achieve this layout without fighting CSS | CC BY-SA 2.5 | null | 2010-12-15T23:17:38.843 | 2010-12-24T04:11:55.767 | 2010-12-16T02:00:08.470 | 544,056 | 544,056 | [
"css",
"templates",
"height",
"html"
] |
4,456,085 | 1 | 4,456,150 | null | 2 | 381 | I'm experimenting with Canvas, placing tokens of different colors on a grid, and trying to remove them.
I'm currently trying to remove the token by drawing a circle of the exact same dimensions in white over the token. This is leaving a "ghostly ring" (single pixel outline) where the original circle was, that disappears with successive applications of the white circle.

The circle in 2, -1 is originally drawn, and not at all overpainted. The circle in 3, -1 has been overpainted once, the circle in 4, -1 has been overpainted twice, and so on to 7, -1.
This behavior occurs in both Chrome and Firefox 3.6
My code follows.
```
function placeToken(e) {
var click = getClick(e);
var gridCord = getGridCord(click);
var canvas = e.currentTarget;
var ctx = canvas.getContext(CONTEXT_NAME);
ctx.fillStyle = color;
ctx.strokeStyle = color; //tried with and without this line, no effect
x = (gridCord.x * spacing) + (spacing / 2);
y = (gridCord.y * spacing) + (spacing / 2);
ctx.beginPath();
ctx.arc(x, y, (spacing - tokenEdge) / 2, 0, Math.PI * 2, true);
ctx.closePath();
ctx.fill();
ctx.stroke(); //tried with and without this line. Same result
};
```
Why does canvas leave this Ghostly ring, and how can I get rid of it?
| Why does Canvas leave a ghostly ring? | CC BY-SA 2.5 | 0 | 2010-12-15T23:38:41.587 | 2010-12-15T23:48:06.983 | null | null | 16,487 | [
"javascript",
"html",
"canvas"
] |
4,456,126 | 1 | 4,456,196 | null | 1 | 1,951 | I have a search input with a default value "Search for".

When I focus on the input the value clears.
```
$(document).ready(function(){
$('#search').focus(function() {
if($(this).val() == "Search for")
$(this).val('');
});
});
```
If you don't type anything to search, what would be a good way to return the default "Search for" value when focusing out?
| Jquery return default input value when focusing out | CC BY-SA 2.5 | 0 | 2010-12-15T23:44:16.053 | 2010-12-16T00:15:19.173 | 2010-12-15T23:52:07.313 | 407,607 | 407,607 | [
"javascript",
"jquery",
"forms",
"search",
"input"
] |
4,456,165 | 1 | 4,456,184 | null | 37 | 73,202 | This is probably a really noob question, but the fact of the matter is that my Code::blocks wouldn't show me errors when it compiles - it only shows a red bar next to the offending line as shown in screenshot. Also, when my code does run and has output, CB opens a new window instead of showing the output in a pane in the bottom of the editor window like some other IDEs. How do I enable either/both, since they're probably the same feature? Thanks!
| Enable compiler output pane in Codeblocks | CC BY-SA 2.5 | 0 | 2010-12-15T23:48:42.323 | 2021-11-04T09:37:48.613 | null | null | 243,500 | [
"ide",
"codeblocks"
] |
4,457,100 | 1 | null | null | 1 | 1,097 | in my app delegate I've this:
```
@implementation UINavigationBar (CustomImage)
- (void)drawRect:(CGRect)rect
{
UIImage *image = [UIImage imageNamed: @"HeaderViewBG.png"];
[image drawInRect:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
}
@end
```
for set a background image for navigationbar. But I need to use a UIImagePickerController, so I've this code:
```
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex {
if (buttonIndex == 1) {
UIImagePickerController *picker = [[UIImagePickerController alloc] init];
picker.delegate = self;
picker.allowsEditing = YES;
picker.navigationBar.barStyle = UIBarStyleDefault;
picker.sourceType = UIImagePickerControllerSourceTypePhotoLibrary;
[self presentModalViewController:picker animated:YES];
[picker release];
}
}
```
The result is:

I want the default UIImagePickerController navigationbar style. I don't want the image background used in application, I want the default navigationbar.
How can I fix it?
Very thanks.
| Problem with NavigationBar and UIImagePickerController | CC BY-SA 2.5 | 0 | 2010-12-16T03:08:12.477 | 2015-07-07T04:29:26.687 | null | null | 521,887 | [
"iphone",
"uiimagepickercontroller",
"uinavigationbar"
] |
4,457,144 | 1 | null | null | 1 | 1,157 | I am having strange problems presenting modal views from landscape orientation. The problem can be recreated by simply starting with a new view-based application and doing the following:
1. Create a new UIViewController subclass that will be presented. I named mine ModalViewController. Change the views background color to make the bug more noticeable.
2. return YES; in both controllers shouldAutorotateToInterfaceOrientation:
3. Add an IBAction to your main view to display the modal and hook this action up to a button in your main view controller. - (IBAction)showModal {
ModalViewController *vc = [[ModalViewController alloc] initWithNibName:@"ModalViewController" bundle:nil];
[self presentModalViewController:vc animated:NO];
[vc release];
}
Now when you click the button from landscape mode you should see the problem. The entire view is shifted up and to the left.
Anyone else experiencing this problem or have any workarounds? I am having similar problems on the iPad.

| iOS modal popover in landscape positioning bug? | CC BY-SA 3.0 | null | 2010-12-16T03:18:18.477 | 2011-09-11T04:00:36.273 | 2011-09-11T04:00:36.273 | 497,356 | 270,903 | [
"ios",
"modal-dialog",
"landscape",
"modalviewcontroller",
"ios-4.2"
] |
4,457,161 | 1 | 4,457,184 | null | 1 | 136 | I already have a limit 20. But how do I also limit the page numbers?

I'm trying to display the first 5 pages than have a ...[$lastpage]
So it would display like this:
```
1 2 3 4 5 ... 64
```
How would I do that? Thanks.
| How do I limit the number of results I get? | CC BY-SA 2.5 | null | 2010-12-16T03:21:56.883 | 2010-12-16T03:53:41.623 | null | null | 415,973 | [
"php"
] |
4,457,239 | 1 | 4,473,054 | null | 0 | 133 | For one of my grid column , xml data is like

But on the grid , dash (-) gets converted into `–` character , like

What's best solution without any change in original data ?
| Flex advance datagrid and dash(-) | CC BY-SA 2.5 | null | 2010-12-16T03:43:37.700 | 2015-09-30T11:21:49.410 | 2015-09-30T11:21:49.410 | 1,213,296 | 263,357 | [
"apache-flex",
"flex3"
] |
4,457,398 | 1 | 4,457,479 | null | 2 | 582 | This issue is minor but is bugging me, why do webKit browsers render the following with extra padding/margin on the bottom? is the only way to solve this to specify heights?
```
<div style="background-color:#efefef; width:200px;">
<textarea style="padding:0px; margin:0px;"></textarea>
</div>
```
Render:

| Why do webKit browsers render the following with extra padding/margin on the bottom? | CC BY-SA 2.5 | null | 2010-12-16T04:20:03.253 | 2010-12-16T04:37:48.717 | null | null | 98,204 | [
"html",
"css",
"google-chrome",
"webkit"
] |
4,457,427 | 1 | null | null | 0 | 1,181 | i really got stuck in a week about this case.
i have a UIBarButtonItem inside UINavigationItem, the hierarchy is like this

The BarButtonItem is a wrapper of segmentedControl. The UIBarbuttonitem and UIsegmentedControl are made programmatically, but the others are made in IB.
in this case, i want to show a view after pressing or touching the barbuttonitem. In several thread i read in this forum, i knew that UIBarbuttonItem didn't inherit UIResponder, so i choose the NavigationBar to get the touch, and i define a frame for it.
this is the code i made :
```
-(void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{
navBar = self.navigationController.navigationBar;
int index = _docSegmentedControl.selectedSegmentIndex;
NSLog(@"index di touches began : %d", index);
CGFloat x;
if (index == 0) {
x = 0.0;
}else if (index == 1) {
x = widthSegment + 1;
}else if (index == 2) {
x = 2*widthSegment + 1;
}else if (index == 3) {
x = 3*widthSegment+ 1;
}else if (in dex == 4) {
x = 4*widthSegment + 1;
}
CGRect frame = CGRectMake(x, 0.00, widthSegment, 46.00);
UITouch *touch = [touches anyObject];
CGPoint gestureStartPoint = [touch locationInView:navBar];
NSLog(@"gesturestart : %f, %f", gestureStartPoint.x, gestureStartPoint.y);
if (CGRectContainsPoint(frame, gestureStartPoint)) {
[NSObject cancelPreviousPerformRequestsWithTarget:self selector:@selector(segmentItemTapped:) object:[self navBar]];
NSLog(@"cancel popover");
}
}
```
the navBar was declare in myViewController.h and i set it as an IBOutlet.
```
-(void)touchesEnded:(NSSet *)touches withEvent:(UIEvent *)event{
int index = _docSegmentedControl.selectedSegmentIndex;
NSLog(@"index di touches ended : %d", index);
navBar = self.navigationController.navigationBar;
CGFloat x;
if (index == 0) {
x = 0.0;
}else if (index == 1) {
x = widthSegment + 1;
}else if (in dex == 2) {
x = 2*widthSegment + 1;
}else if (index == 3) {
x = 3*widthSegment+ 1;
}else if (index == 4) {
x = 4*widthSegment + 1;
}
CGRect frame = CGRectMake(x, 0.00, widthSegment, 46.00);
UITouch *touch = [touches anyObject];
CGPoint gestureLastPoint = [touch locationInView:navBar];
NSLog(@"lastPOint : %d", gestureLastPoint);
if (CGRectContainsPoint(frame, gestureLastPoint)) {
if (touch.tapCount <= 2) {
[self performSelector:@selector(segmentItemTapped:) withObject:nil afterDelay:0.0];
}
}
}
```
touchesBegan and touchesEnded was detected when i tap at the toolbar, NOT in the navbar.
i did implemented the hitTest method like this :
```
- (UIView *)hitTest:(CGPoint)point withEvent:(UIEvent *)event {
UIView *touchedView = [super hitTest:point withEvent:event];
NSSet* touches = [event allTouches];
// handle touches if you need
return touchedView;
}
```
but it still nothing get better.
Somebody can decribe why this is happen?
Regards
-Risma-
| touchesBegan and touchesEnded detected on another subview | CC BY-SA 2.5 | null | 2010-12-16T04:28:26.170 | 2010-12-17T06:43:53.003 | 2010-12-17T06:43:53.003 | 515,986 | 515,986 | [
"ipad",
"uinavigationcontroller",
"uinavigationbar",
"uibarbuttonitem",
"touchesbegan"
] |
4,457,598 | 1 | null | null | 0 | 281 | Using Microsoft Excel 2007 (or 2002) is it possible to create pivot data like this?

Specifically I would like to know if I can display '01(Y 0)' as a non-calculated text value instead of just a SUM/COUNT/MAX/etc value.
| Tweaking a Excel Pivot Table to display a OrderNumber instead of a calculation? | CC BY-SA 2.5 | null | 2010-12-16T05:03:29.017 | 2015-05-15T18:09:21.890 | 2015-05-15T18:09:21.890 | 640,595 | 127,776 | [
"excel-2007",
"pivot-table"
] |
4,457,607 | 1 | 4,457,693 | null | 2 | 34,664 | This is a rather simple question, I am having problems inserting data from Javascript into an HTML table.
Here is an excerpt of my JavaScript:
UPDATED - I got rid of the two loops and simplified it into one, however there is still a problem..
```
for (index = 0; index < enteredStrings.length; index++) {
output.innerHTML += "<td>" + enteredStrings[index] + "</td>"
+ "<td>" + enteredStringsTwo[index] + "</td>";
nameCounter++;
total.innerHTML = "Total: " + nameCounter;
}
```
And here is an except of my HTML page:
```
<table id="nameTable">
<tr>
<th>First</th><th>Last</th>
</tr>
```
Updated Picture:

| Javascript inserting data into HTML table | CC BY-SA 2.5 | 0 | 2010-12-16T05:06:08.510 | 2012-09-30T21:32:04.233 | 2010-12-16T06:02:54.427 | 461,078 | 461,078 | [
"javascript",
"html"
] |
4,457,779 | 1 | 4,457,803 | null | 7 | 9,508 | Here's my code:
```
UILabel *myLabel;
myLabel = [[UILabel alloc] initWithFrame:CGRectMake(20, 0, 300, 480)];
myLabel.lineBreakMode = UILineBreakModeWordWrap;
myLabel.numberOfLines = 2; // 2 lines ; 0 - dynamical number of lines
myLabel.text = @"Please select at least one image category!";
myLabel.font = [UIFont fontWithName:@"Arial-BoldMT" size: 24.0];
myLabel.center = CGPointMake(self.view.frame.size.width/2, self.view.frame.size.height/2);
myLabel.backgroundColor = [UIColor clearColor];
[self.view addSubview:myLabel];
[myLabel release];
```
I was wondering if it is possible to center the wrapped text as it is alined to the left side:

| UILabel Center contents | CC BY-SA 2.5 | 0 | 2010-12-16T05:40:59.037 | 2014-04-14T15:22:15.370 | 2013-04-09T16:01:48.210 | 1,849,664 | 524,358 | [
"iphone",
"ios",
"text",
"uilabel"
] |
4,457,888 | 1 | null | null | 1 | 2,234 | I am new to GM and trying to write my first user script. I am trying to get a URL from a facebook comment I was trying to use this.
```
var e = Array.filter( document.getElementsByClassName('UIStoryAttachment_Title'), function(elem) {
return elem.nodeName == 'A';
}
);
```
But each time I seem to open up a blank page any help on this would be great

| GreaseMonkey Help with getElementsByClassName | CC BY-SA 2.5 | 0 | 2010-12-16T06:02:20.740 | 2010-12-16T06:44:05.820 | null | null | 356,993 | [
"javascript",
"greasemonkey"
] |
4,457,955 | 1 | 4,459,825 | null | 1 | 712 | this is my alwaysdata page - [http://zjm.alwaysdata.net/](http://zjm.alwaysdata.net/):

It is not configured successful , when i Visit the [http://zjm.alwaysdata.net/mysite/public/](http://zjm.alwaysdata.net/mysite/public/)
it show my main page :

so what can i do to show my main-page on the [http://zjm.alwaysdata.net/](http://zjm.alwaysdata.net/)
thanks
this is my `django.fcgi` :
```
#!/usr/bin/python
import os, sys
_PROJECT_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
sys.path.insert(0, _PROJECT_DIR)
sys.path.insert(0, os.path.dirname(_PROJECT_DIR))
_PROJECT_NAME = _PROJECT_DIR.split('/')[-1]
os.environ['DJANGO_SETTINGS_MODULE'] = "%s.settings" % _PROJECT_NAME
from django.core.servers.fastcgi import runfastcgi
runfastcgi(method="threaded", daemonize="false")
```
and `.htaccess` :
```
AddHandler fcgid-script .fcgi
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ django.fcgi/$1 [QSA,L]
```
this is my urls.py:
```
from django.conf.urls.defaults import *
# Uncomment the next two lines to enable the admin:
# from django.contrib import admin
# admin.autodiscover()
from views import *
urlpatterns = patterns('',
# Example:
#(r'^$', homepage),
# (r'^mysite/', include('mysite.foo.urls')),
# Uncomment the admin/doc line below to enable admin documentation:
# (r'^admin/doc/', include('django.contrib.admindocs.urls')),
# Uncomment the next line to enable the admin:
# (r'^admin/', include(admin.site.urls)),
)
```
| django hosting error , about alwaysdata.com | CC BY-SA 2.5 | null | 2010-12-16T06:10:40.887 | 2017-07-10T16:20:52.770 | 2010-12-16T08:05:49.983 | 420,840 | 420,840 | [
"python",
"django",
"hosting",
"fastcgi"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.