Search Results

Search found 19385 results on 776 pages for 'canonical link'.

Page 66/776 | < Previous Page | 62 63 64 65 66 67 68 69 70 71 72 73  | Next Page >

  • WCF hosting: Can access svc file but cannot go to wsdl link

    - by Impulse
    Hello, I have a WCF service that is hosted in IIS 7.5. I have two servers, one for test and one for production. The service works fine on test server, but on the production server I have the following error. When I access the address http//..../service.svc I can see the default page that says: You have created a service. To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax: svcutil.exe http://..../service.svc?wsdl This will generate a configuration file and a code file that contains the client class. Add the two files to your client application and use the generated client class to call the Service. But when I click the wsdl link, I cannot go to the wsdl page. It returns me to this default web page without any errors. I am suspecting a network/firewall authorization error but does anybody have an experience like this one? All IIS settings are the same for test and production servers. Thank you, Best Regards.

    Read the article

  • measure the response time of a link

    - by Ahoura Ghotbi
    I am trying to create a simple load balance script and I was wondering if it is possible to find the response time of a server live? By that I mean is it possible to measure how long it takes for a server to respond after the request has been sent out? What I am trying to do is fairly simple, I want to send a request to a link/server and do a count down, if the server took more than 5 seconds to reply, I would like to fall on the backup server. Note that it doesnt have to be in pure php, I wouldnt mind using other languages such as javascript, C/C++, asp, but I prefer to do it in PHP. if it is possible to do the task, could you just point me to the right direction so I can read up on it. Clarification What I want to do is not to download a file and see how long it took, my servers have high load and it takes a while for them to respond when you click on a file to download, what I want to do is to measure the time it takes the server to respond (in this situation, its the time it takes the server to respond and allow the user to download the file), and if it takes longer than x seconds, it should fall back on a backup server.

    Read the article

  • Only show link if conditional equals true

    - by Dave Morin
    I want the link to appear only when $data['block'] equals to 1, 3 or 4. Not if it equals to 2 or 5. <td style="font-size:18px;color:#f0cb01;"> <a href="kickcodes.php?id='.$data["block"].'">Reason Codes</a> </td> EDIT while ($data = mysql_fetch_array($query)) { echo ' <tr style="background-color:#576c11;"> <td style="font-size:18px; color:#f0cb01;">'.$data["keyword"].'</td> <td style="font-size:18px;color:#f0cb01;">'.$data["block"].'</td> <td style="font-size:18px;color:#f0cb01;">'.$data["phone"].'</td> <td style="font-size:18px;color:#f0cb01;">'.$data["Reason"].'</td> <td style="font-size:18px;color:#f0cb01;"><a href="kickcodes.php?id='.$data ["block"].'">Kickcodes</a></td>' echo '<td style="font-size:18px;color:#f0cb01;">'; if( $data['block'] == 1 || $data['block'] == 3 || $data['block'] == 4) { echo '<a href="kickcodes.php?id='.$data["block"].'">Reason Codes</a>'; } else { echo '<span>Reason Codes</span>'; // Or echo nothing } echo '</td>';

    Read the article

  • Target a link if that link links to the current page?

    - by Des
    this may be a stupid question as I can't seem to find an answer :P Is there a way with javascript/jQuery to Target all links on a page ONLY if they link to the current page? Say i've got a static sidebar on ALL pages, for intents and purposes: <ul id="sidebar"> <li><a href="/one">One</a></li> <li><a href="/two">Two</a></li> <li><a href="/three">Three</a></li> </ul> Notice the code for ALL of them is the same. Let's say I'm on "www.domain.com/two" - Is there a way to target <li><a href="#">Two</a></li> because it's linking to the current page? ***ANSWERED***** The guy deleted his answer - but I used it to create this - var linksToCurrentPage = $('a[href="' + window.location.href + '"]'); if (linksToCurrentPage) { $('a').addClass('currently-active'); }; which worked :)

    Read the article

  • Data Structure / Hash Function to link Sets of Ints to Value

    - by Gaminic
    Given n integer id's, I wish to link all possible sets of up to k id's to a constant value. What I'm looking for is a way to translate sets (e.g. {1, 5}, {1, 3, 5} and {1, 2, 3, 4, 5, 6, 7}) to unique values. Guarantees: n < 100 and k < 10 (again: set sizes will range in [1, k]). The order of id's doesn't matter: {1, 5} == {5, 1}. All combinations are possible, but some may be excluded. All sets and values are constant and made only once. No deletes or inserts, no value updates. Once generated, the only operations taking place will be look-ups. Look-ups will be frequent and one-directional (given set, look up value). There is no need to sort (or otherwise organize) the values. Additionally, it would be nice (but not obligatory) if "neighboring" sets (drop one id, add one id, swap one id, etc) are easy to reach, as well as "all sets that include at least this set". Any ideas?

    Read the article

  • In C/C++,how to link dynamic link lib which compiled in GCC/G++ in MS VStudio?

    - by coanor
    These days, I use Flex & Bison generated some codes to develop a SQL-parser alike tools, these code can't compiled silently(may be this another topic) in VS2005,but GCC/G++ works well, then I compiled these code with mingw in dll(in windows xp), and then linked these function facades in VS2005, but it seems can't link the dll during linking. Does MS VS2005 recognize the dll which compiled using mingw on windows? Is there anything I need to do additional? For example, adding something in the include-file that declare the exported APIs? Does any one can give some advices? The condition is, as in VS2005, if you want to export some APIs, you may show a *.def file to tell nmake which API you want to export, and then you may create a(or some) *.h file to declare somthing about these APIs(adding some stdcall alike prefix as a call protocal) and some data-type definition. But with GCC/G++, you do not need to do such boring things, just use [ar], you can get these APIs, so my *.h file do not add call protocol and no *.def, just like common function declaration. After *.dll generated, add the *.h file and [mv] generated *.dll in VS2005 project directory, then set the linking *.dll in project setting. Does these steps generated my Question? BTW, I found and tested VC6-compiled dll can be linked with mingw in Windows XP, but the reverse can't work. Anyway, forgive my poor English, and thanks for your concern.

    Read the article

  • How to remove the link if value is 0 using asp.net mvc

    - by kumar
    i have this code.. <table class="dashboard-table"> <thead> <tr> <th>&nbsp;</th> <th>Worked</th> </tr> </thead> <% foreach (var e in Model.ExceptionsByType) { %> <tr> <td> <%=Html.ActionLink(e.ExceptionTypeName, "VirtualScrollingDataRequested", Model.exceptionCategory.GetControllerName(), new { C_EXCPT_TYPE = e.ExceptionTypeID, GUI_SPEC_STAT_DSPL = 2, C_EXCPT_CATG = Model.exceptionCategory.Id, @ASSET_CLASS = string.Empty, @INST_MNEM = string.Empty, @_lock = "ALL" }, new { @title = e.BuildGridTitle(2, e.ExceptionTypeName) })%> </td> <td class="number"> <%=e.WorkedExceptions %> </td> </tr> <% } %> </table> e.WorkedExceptions is the count of exceptions.. I need to to the condition here if the e.workedexceptions == 0 I need to remove the link? please can any body hlep me out? thanks

    Read the article

  • Delete file using a link

    - by user329394
    Hi all, i want to have function like delete file from database by using link instead of button. how can i do that? do i need to use href/unlink or what? Can i do like popup confirmation wther yes or no. i know how to do that, but where should i put the code? this is the part how where system will display all filename and do direct upload. Beside each files, there will be a function for 'Remove': $qry = "SELECT * FROM table1 a, table2 b WHERE b.id = '".$rs[id]."' AND a.ptkid = '".$rs[id]."' "; $sql = get_records_sql($qry); foreach($sql as $rs){ ?> <?echo '<a href="download.php?f='.$rs->faillampiran.'">'. basename($rs->faillampiran).'</a>'; ?><td><?echo '<a href=""> [Remove]</a>';?></td><? ?><br> <? } ?> thankz all

    Read the article

  • jQuery replacement for Default Button or Link

    - by pyccki
    As everyone knows, that default button doesn't work in FF, only IE. I've tried to put in the tag or in the and it's not working. I've found a js script to fix this issue, but for some reason it's not working for me. This script for a submit button, i need to use it for a LinkButton, which is should be the same. Link: <div id="pnl"> <a id="ctl00_cphMain_lbLogin" title="Click Here to LogIn" href="javascript:WebForm_DoPostBackWithOptions(new WebForm_PostBackOptions(&quot;ctl00$cphMain$lbLogin&quot;, &quot;&quot;, true, &quot;Login1&quot;, &quot;&quot;, false, true))">Log In</a> <input name="ctl00$cphMain$UserName" type="text" id="ctl00_cphMain_UserName" /> <input name="ctl00$cphMain$UserName" type="text" id="ctl00_cphMain_UserName1" /> </div> <script> $(document).ready(function() { $("#pnl").keypress(function(e) { if ((e.which && e.which == 13) || (e.keyCode && e.keyCode == 13)) { $("a[id$='_lbLogin']").click(); return true; } }); }); I know that i can override original function "*WebForm_FireDefaultButton*" in This post, but i really wanted to get this one to work. Thanx in advance!!!

    Read the article

  • Changing PHP variable from an <a href=""> link

    - by aener
    I'm making a site using divs. I have one across the top with a row of links which I want to change what's in the main window. I would prefer to keep strictly to PHP and HTML and use a full page refresh as I am comfortable with them at current, rather than using an Ajax refresh as I don't have any knowledge of Ajax. I don't want to use iframes. I thought the best way to do this would be as follows: <div id="top"> <a href="news.html">News</a> </div> <div id="main"> <?php include($page); ?> </div> What I need is a way of changing the $page variable upon clicking the link. If this means changing the variable and then reloading the page then so be it. A command following the logic of: <a href="news.html" action="<?php $page="news.html"; ?>">News</a> would be ideal! I thought about using a form, but it seems there should be an easier way.

    Read the article

  • why my pagination link doesnt appear ?

    - by udaya
    This is my script which i have used to paginate ,,The datas are restricted to 4 but the pagination link doesn't appear <? require_once ('Pager/Pager.php'); $connection = mysql_connect( "localhost" , "root" , "" ); mysql_select_db( "ssit",$connection); $result=mysql_query("SELECT dFrindName FROM tbl_friendslist", $connection); $row = mysql_fetch_array($result); $totalItems = $row['total']; $pager_options = array( 'mode' => 'Sliding', // Sliding or Jumping mode. See below. 'perPage' => 4, // Total rows to show per page 'delta' => 4, // See below 'totalItems' => $totalItems, ); $pager = Pager::factory($pager_options); echo $pager->links; list($from, $to) = $pager->getOffsetByPageId(); $from = $from - 1; $perPage = $pager_options['perPage']; $result = mysql_query("SELECT * FROM tbl_friendslist LIMIT 5 , $perPage",$connection); while($row = mysql_fetch_array($result)) { echo $row['dFrindName'].'</br>'; } ?>

    Read the article

  • Getting a Script Error Every Time I Click a Link

    - by Flip4Life
    I have everything working perfectly on my site, but for some reason, I get an error message in console whenever I click a link anywhere on my site. The error has to do with this line of coding here: jQuery(function($){ $('.navbar a, .scroll a, .smoothscroll a').bind('click',function(event){ var $anchor = $(this); $('html, body').stop().animate({ scrollTop: $($anchor.attr('href')).offset().top }, 850,'easeInOutExpo'); event.preventDefault(); }); }); And the error I am getting is this: "SCRIPT5007: Unable to get value of the property 'top': object is null or undefined custom.min.js, line 6 character 197" The exact code it is highlighting is this part of the above code: $('html, body').stop().animate({ scrollTop: $($anchor.attr('href')).offset().top }, 850,'easeInOutExpo') All I know is that when I remove the above code, my scroll-to links stop working on pages such as these: http://www.northtownsremodeling.com/things-to-know.php You can see the popup error happen and stay in the console easily by going to a page with a filter like this: http://www.northtownsremodeling.com/bathroom/ And clicking one of the filter buttons. Ultimately, I am trying to make it so my scroll-to setting still works, but not have that error come up anymore. I made this script a long time ago, and I'm really confused as to what could be causing this error when everything is functioning perfectly otherwise? Thanks!

    Read the article

  • Save Cookies, Then Open Link in New Tab

    - by speedplane
    I have some javascript code that saves a cookie. However, if after saving the cookie, the user opens a new tab, it appears that the cookie is not saved. The new tab is on the same domain. Here is my cookie setting/getting code: function setCookie(c_name,value,exdays) { var exdate=new Date(); exdate.setDate(exdate.getDate() + exdays); var c_value=escape(value) + ((exdays==null) ? "" : "; expires="+exdate.toUTCString()); document.cookie=c_name + "=" + c_value; } function getCookie(c_name) { var i,x,y,ARRcookies=document.cookie.split(";"); for (i=0;i<ARRcookies.length;i++) { x=ARRcookies[i].substr(0,ARRcookies[i].indexOf("=")); y=ARRcookies[i].substr(ARRcookies[i].indexOf("=")+1); x=x.replace(/^\s+|\s+$/g,""); if (x==c_name) { return unescape(y); } } } If some javascript calls setCookie('mycookie', 1) and then the user clicks on a link where the _target is set to _blank, the cookie does not load in the new tab. So getCookie('mycookie') will not return 1. What is the problem here?

    Read the article

  • Drupal Adding Span inside A tags in Nice Menus

    - by Chris
    I am trying to add drop down menus to a drupal theme which uses text sliding door CSS rounding. The current version uses a primary links injection of the span into the a tags, which works fine. But doesn't support drop down menus. Working code: <?php print theme('links', $primary_links, array('class' => 'links primary-links')) ?> In the template with a template.php file addition: <?php // function for injecting spans inside anchors which we need for the theme's rounded corner background images function strands_guybrush_links($links, $attributes = array('class' => 'links')) { $output = ''; if (count($links) > 0) { $output = '<ul'. drupal_attributes($attributes) .'>'; $num_links = count($links); $i = 1; foreach ($links as $key => $link) { $class = $key; // Add first, last and active classes to the list of links to help out themers. if ($i == 1) { $class .= ' first'; } if ($i == $num_links) { $class .= ' last'; } if (isset($link['href']) && ($link['href'] == $_GET['q'] || ($link['href'] == '<front>' && drupal_is_front_page()))) { $class .= ' active'; } $output .= '<li'. drupal_attributes(array('class' => $class)) .'>'; if (isset($link['href'])) { $link['title'] = '<span class="link">' . check_plain($link['title']) . '</span>'; $link['html'] = TRUE; // Pass in $link as $options, they share the same keys. $output .= l($link['title'], $link['href'], $link); } else if (!empty($link['title'])) { // Some links are actually not links, but we wrap these in <span> for adding title and class attributes if (empty($link['html'])) { $link['title'] = check_plain($link['title']); } $span_attributes = ''; if (isset($link['attributes'])) { $span_attributes = drupal_attributes($link['attributes']); } $output .= '<span'. $span_attributes .'>'. $link['title'] .'</span>'; } $i++; $output .= "</li>\n"; } $output .= '</ul>'; } return $output; } ?> So I have added the [Nice Menu module][1] which works well and allows the drop down menu functions for my navigation which is now addressed from the template using: <?php print theme_nice_menu_primary_links() ?> The issue is that the a tags need to have spans inside to allow for the selected state markup. I have tried every angle I could find to edit the drupal function menu_item_link which is used by nice menus to build the links. E.g. I looked at the drupal forum for two days and no joy. The lines in the module that build the links are: function theme_nice_menu_build($menu) { $output = ''; // Find the active trail and pull out the menus ids. menu_set_active_menu_name('primary-links'); $trail = menu_get_active_trail('primary-links'); foreach ($trail as $item) { $trail_ids[] = $item['mlid']; } foreach ($menu as $menu_item) { $mlid = $menu_item['link']['mlid']; // Check to see if it is a visible menu item. if ($menu_item['link']['hidden'] == 0) { // Build class name based on menu path // e.g. to give each menu item individual style. // Strip funny symbols. $clean_path = str_replace(array('http://', '<', '>', '&', '=', '?', ':'), '', $menu_item['link']['href']); // Convert slashes to dashes. $clean_path = str_replace('/', '-', $clean_path); $class = 'menu-path-'. $clean_path; $class .= in_array($mlid, $trail_ids) ? ' active' : ''; // If it has children build a nice little tree under it. if ((!empty($menu_item['link']['has_children'])) && (!empty($menu_item['below']))) { // Keep passing children into the function 'til we get them all. $children = theme('nice_menu_build', $menu_item['below']); // Set the class to parent only of children are displayed. $class .= $children ? ' menuparent ' : ''; // Add an expanded class for items in the menu trail. $output .= '<li id="menu-'. $mlid .'" class="'. $class .'">'. theme('menu_item_link', $menu_item['link']); // Build the child UL only if children are displayed for the user. if ($children) { $output .= '<ul>'; $output .= $children; $output .= "</ul>\n"; } $output .= "</li>\n"; } else { $output .= '<li id="menu-'. $mlid .'" class="'. $class .'">'. theme('menu_item_link', $menu_item['link']) .'</li>'."\n"; } } } return $output; } As you can see the $output uses menu_item_link to parse the array into links and to added the class of active to the selected navigation link. The question is how do I add a span inside the a tags OR how do I wrap the a tags with a span that has the active class to style the sliding door links? drupal.org/project/nice_menus drupal.org/node/53233

    Read the article

  • MinGW/G++/g95 link problem - libf95 undefined reference to `MAIN_'

    - by pivakaka
    Hi folks, Summing up, my problem consists on compiling g95 objects inside a C++ application. Actually, I'm constructing an interface for an old fortran program. For this task, I'm using the wxWidgets GUI library, and calling fortran subroutines when necessary. At the beginning, I was developing the entire project compiling my fortran files with gfortran (which comes with GCC) and linking them with my app by the g++ -o... command. Everything was working fine but some numbers values calculated by my fotran subroutines returned NAN values. Doing some research, I realized that compiling my fortran files with gfortran with the -m32 flag, generates this NAN values problem. Although compiling with -m64 flag, my code works properly well. The only trouble here is that my App should be 32bits and then I tryed another compiller. Here I found g95 Fortran compiler, which compiles my fortran code and gives the right output on a 32bits environment. But when I'm trying to link these g95 objects into my program I see this following error: g++ -oCyclonTechTower.exe src\fortran\Modulo_Global.o src\fortran\Prop_Fisicas.o src\fortran\inversa.o src\fortran\tower.o src\fortran\PredadeCarga.o src\fortran\gota.o src\fortran\tadi.o src\view\SimulationORSATCustomDialog.o src\view\SimulationChildGUIFrame.o src\view\ParentGUIFrame.o src\view\ClientGUIFrame.o src\model\TowerData.o src\controller\SimulationController.o src\THEIACyclonTechTower.o ..\Resource\resource.o -Lc:\wxWidgets-2.6.4\lib -Lc:\MinGW\lib\gcc-lib\i686-pc-mingw32\4.1.2 -Bdynamic -Wl,--subsystem,windows -mwindows c:\wxWidgets-2.6.4\lib\libwx_mswu-2.6.a -lwxregexu-2.6 -lwxexpat-2.6 -lwxtiff-2.6 -lwxjpeg-2.6 -lwxpng-2.6 -lwxzlib-2.6 -lrpcrt4 -loleaut32 -lole32 -luuid -lwinspool -lwinmm -lshell32 -lcomctl32 -lcomdlg32 -lctl3d32 -ladvapi32 -lwsock32 -lgdi32 -lgcc -lf95 c:\MinGW\lib\gcc-lib\i686-pc-mingw32\4.1.2/libf95.a(main.o):(.text+0x32): undefined reference to `MAIN_' collect2: ld returned 1 exit status Build error occurred, build is stopped Time consumed: 1531 ms. I have already read the g95 Manual for integration with C++ and I'm actually calling these functions bellow for controlling the fortran environment: void g95_runtime_start(int argc, char *argv[]); void g95_runtime_stop(); I also included the g95 Fortran Runtime Library libf95.a and the libgcc.a into my linker command. Finishing, I don't have a main method implemented because this is managed by wxWidgets, and my fortran subroutines can not have a main function because this is a C++ program calling fortran functions. Can some of you guys help me with this problem? How can I fix this undefined reference to MAIN__ problem? Any idea will be much appreciated. Thanks in advance, George

    Read the article

  • Download And Install apk from a link.

    - by rayman
    Hi, I`am trying to download and install an apk from some link, but for some reason i get an exception. I have one method downloadfile() which downloading the file and a call to and installFile() method, which supposed to install it in the device. some code: public void downloadFile() { String fileName = "someApplication.apk"; MsgProxyLogger.debug(TAG, "TAG:Starting to download"); try { URL u = new URL( "http://10.122.233.22/test/someApplication.apk"); try { HttpURLConnection c = (HttpURLConnection) u.openConnection(); try { c.setRequestMethod("GET"); c.setDoOutput(true); try { c.connect(); FileOutputStream f = context.openFileOutput(fileName, context.MODE_WORLD_READABLE); try { InputStream in = c.getInputStream(); byte[] buffer = new byte[1024]; int len1 = 0; int totsize = 0; try { while ((len1 = in.read(buffer)) > 0) { totsize += len1; f.write(buffer, 0, len1);// .write(buffer); } } catch (IOException e) { e.printStackTrace(); } f.close(); MsgProxyLogger.debug(TAG, TAG + ":Saved file with name: " + fileName); InstallFile(fileName); } catch (IOException e) { e.printStackTrace(); } } catch (IOException e) { e.printStackTrace(); } } catch (ProtocolException e) { e.printStackTrace(); } } catch (IOException e) { e.printStackTrace(); } } catch (MalformedURLException e) { e.printStackTrace(); } } and this is the install file method: private void InstallFile(String fileName) { MsgProxyLogger.debug(TAG, TAG + ":Installing file " + fileName); String src = String.format( "file:///data/data/com.test/files/", fileName); Uri mPackageURI = Uri.parse(src); PackageManager pm = context.getPackageManager(); int installFlags = 0; try { PackageInfo pi = pm.getPackageInfo("com.mirs.agentcore.msgproxy", PackageManager.GET_UNINSTALLED_PACKAGES); if (pi != null) { MsgProxyLogger.debug(TAG, TAG + ":replacing " + fileName); installFlags |= PackageManager.REPLACE_EXISTING_PACKAGE; } } catch (NameNotFoundException e) { } try { // PackageInstallObserver observer = new PackageInstallObserver(); pm.installPackage(mPackageURI); } catch (SecurityException e) { //!!!!!!!!!!!!!here i get an security exception!!!!!!!!!!! MsgProxyLogger.debug(TAG, TAG + ":not permission? " + fileName); } this is the exception details: "Neither user 10057 nor current process has android.permission.INSTALL_PACKAGES". and i have set in my main app that permission in the manifest. anyone has any idea? thanks, ray.

    Read the article

  • More GCC link time issues: undefined reference to main

    - by vikramtheone
    Hi Guys, I'm writing software for a Cortex-A8 processor and I have to write some ARM assembly code to access specific registers. I'm making use of the gnu compilers and related tool chains, these tools are installed on the processor board(Freescale i.MX515) with Ubuntu. I make a connection to it from my host PC(Windows) using WinSCP and the PuTTY terminal. As usual I started with a simple C project having main.c and functions.s. I compile the main.c using GCC, assemble the functions.s using as and link the generated object files using once again GCC, but I get strange errors during this process. An important finding - Meanwhile, I found out that my assembly code may have some issues because when I individually assemble it using the command as -o functions.o functions.s and try running the generated functions.o using ./functions.o command, the bash shell is failing to recognize this file as an executable(on pressing tab functions.o is not getting selected/PuTTY is not highlighting the file). Can anyone suggest whats happening here? Are there any specific options I have to send, to GCC during the linking process? The errors I see are strange and beyond my understanding, I don't understand to what the GCC is referring. I'm pasting here the contents of main.c, functions.s, the Makefile and the list of errors. Help, please!!! Vikram main.c #include <stdio.h> #include <stdlib.h> int main(void) { puts("!!!Hello World!!!"); /* prints !!!Hello World!!! */ return EXIT_SUCCESS; } functions.s * Main program */ .equ STACK_TOP, 0x20000800 .text .global _start .syntax unified _start: .word STACK_TOP, start .type start, function start: movs r0, #10 movs r1, #0 .end Makefile all: hello hello: main.o functions.o gcc -o main.o functions.o main.o: main.c gcc -c -mcpu=cortex-a8 main.c functions.o: functions.s as -mcpu=cortex-a8 -o functions.o functions.s Errors ubuntu@ubuntu-desktop:~/Documents/Project/Others/helloworld$ make gcc -c -mcpu=cortex-a8 main.c as -mcpu=cortex-a8 -o functions.o functions.s gcc -o main.o functions.o functions.o: In function `_start': (.text+0x0): multiple definition of `_start' /usr/lib/gcc/arm-linux-gnueabi/4.3.3/../../../crt1.o:init.c:(.text+0x0): first defined here /usr/lib/gcc/arm-linux-gnueabi/4.3.3/../../../crt1.o: In function `_start': init.c:(.text+0x30): undefined reference to `main' collect2: ld returned 1 exit status make: *** [hello] Error 1

    Read the article

  • Having a Link Only Appear If a Logged-In User Appears on a Dynamic List

    - by John
    Hello, For the function below, I would like the link <div class="footervote"><a href="http://www...com/.../footervote.php">Vote</a></div> to only appear if the logged in user currently appears on editorlist.php. (I. e. if the loginid in the function corresponds to any of the usernames that currently appear in editorlist.php.) Appearing on editorlist.php is something that is dynamic. How can I do this? Thanks in advance, John function show_userbox() { // retrieve the session information $u = $_SESSION['username']; $uid = $_SESSION['loginid']; // display the user box echo '<div id="userbox"> <div class="username">'.$u.'</div> <div class="submit"><a href="http://www...com/.../submit.php">Submit an item.</a></div> <div class="changepassword"><a href="http://www...com/.../changepassword.php">Change Password</a></div> <div class="logout"><a href="http://www...com/.../logout.php">Logout</a></div> <div class="footervote"><a href="http://www...com/.../footervote.php">Vote</a></div> </div>'; } On editorlist.php: $sqlStr = "SELECT l.loginid, l.username, l.created, DATEDIFF(NOW(), l.created) AS days, COALESCE(s.total, 0) AS countSubmissions, COALESCE(c.total, 0) AS countComments, COALESCE(s.total, 0) * 10 + COALESCE(c.total, 0) AS totalScore, DATEDIFF(NOW(), l.created) + COALESCE(s.total, 0) * 10 + COALESCE(c.total, 0) AS totalScore2 FROM login l LEFT JOIN ( SELECT loginid, COUNT(1) AS total FROM submission GROUP BY loginid ) s ON l.loginid = s.loginid LEFT JOIN ( SELECT loginid, COUNT(1) AS total FROM comment GROUP BY loginid ) c ON l.loginid = c.loginid GROUP BY l.loginid ORDER BY totalScore2 DESC LIMIT 10"; $result = mysql_query($sqlStr); $arr = array(); echo "<table class=\"samplesrec1edit\">"; while ($row = mysql_fetch_array($result)) { echo '<tr>'; echo '<td class="sitename1edit1"><a href="http://www...com/.../members/index.php?profile='.$row["username"].'">'.stripslashes($row["username"]).'</a></td>'; echo '<td class="sitename1edit2">'.($row["countSubmissions"]).'</td>'; echo '<td class="sitename1edit2">'.($row["countComments"]).'</td>'; echo '<td class="sitename1edit2">'.($row["days"]).'</td>'; echo '<td class="sitename1edit2">'.($row["totalScore2"]).'</td>'; echo '</tr>'; } echo "</table>";

    Read the article

  • Refactor a link and an image

    - by Mihail Stoynov
    I have to write an link with an image inside. Instead of explaining, here's the code I have now: <c:if test="${userSession.loggedUser eq null and company.image != null}"> <a onclick="${rich:component('loginPanel')}.show()"> <img src="/download.do?hash=#{company.image.hash}" /> </a> </c:if> <c:if test="${userSession.loggedUser eq null and company.image == null}"> <a onclick="${rich:component('loginPanel')}.show()"> <img src="${request.contextPath}/img/icons/logo_default.jpg" /> </a> </c:if> <c:if test="${userSession.loggedUser ne null and company.image != null}"> <a href="company.xhtml?${company.name}"> <img src="/download.do?hash=#{company.image.hash}" /> </a> </c:if> <c:if test="#{userSession.loggedUser ne null and company.image == null}"> <a href="company.xhtml?${company.name}"> <img src="${request.contextPath}/img/icons/logo_default.jpg" /> </a> </c:if> This code looks awful - there are two exact links with two exact images but combined in all possible combinations. Is there a better way? Is there a way to avoid c:if - it created tables? Update: Bozho proposes: You can replace <c:if and <a with <h:outputLink rendered="#{..}". Apart from that I don't see any other optimization. But it doesn't work. This does not render correctly: <a href=> <h:outputLink rendered="#{..} <h:outputLink rendered="#{..} </a> (the image is outside the anchor) This does render fine: <h:outputLink value=> <h:outputLink rendered="#{..} <h:outputLink rendered="#{..} </a> , but it always adds href and in two of the cases I don't want href when rendered.

    Read the article

  • style a navigation link when a particular div is shown

    - by Matt Meadows
    I have JQuery working to show a particular div when a certain link is clicked. I have managed to apply the effect I'm after with the main navigation bar through id'ing the body tag and using css to style when the id is found. However, i'd like to apply the same effect to the sub navigation when a certain div is present. How the main navigation is styled: HTML: <nav> <ul> <li id="nav-home"><a href="index.html">Home</a></li> <li id="nav-showreel"><a href="showreel.html">Showreel</a></li> <li id="nav-portfolio"><a href="portfolio.html">Portfolio</a></li> <li>Contact</li> </ul> </nav> CSS: body#home li#nav-home, body#portfolio li#nav-portfolio { background: url("Images/Nav_Underline.png") no-repeat; background-position: center bottom; color: white; } (Other links havent been added to styling as those pages are still in development) How the sub navigation is structured: <nav id="portfolioNav"> <ul> <li id="portfolio-compositing"><a id="compositingWork" href="#">Compositing</a></li> <li id="portfolio-animation"><a id="animationWork" href="#">Animation</a></li> <li id="portfolio-motionGfx"><a id="GFXWork" href="#">Motion Graphics</a></li> <li id="portfolio-3D"><a id="3DWork" href="#">3D</a></li> </ul> </nav> As you can see, its similar format to the main navigation, however i've tried the same approach and it doesn't work :( The Javascript that switches the divs on the navigation click: <script type="text/javascript"> $(document).ready(function() { $('#3DWork').click(function(){ $('#portfolioWork').load('portfolioContent.html #Portfolio3D'); }); $('#GFXWork').click(function(){ $('#portfolioWork').load('portfolioContent.html #motionGraphics'); }); $('#compositingWork').click(function(){ $('#portfolioWork').load('portfolioContent.html #PortfolioCompositing'); }); $('#animationWork').click(function(){ $('#portfolioWork').load('portfolioContent.html #PortfolioAnimation'); }); }); </script> JSFiddle for full HTML & CSS : JSFiddle File The effect I'm After:

    Read the article

  • Which one is better? To have link on one page or on all pages?

    - by Ervin
    I have a website: http://www.amenajari-gradini-mures.ro and I will put links on http://www.casesigradini.ro . I would like to know which one is better from the point of view of SEO: - to have one single link on the homepage OR - to have a link on every page (about 48000 pages) ? Right now I got my link up on every page. But if it's better to have it on one page only (or maybe on few main pages ) then i'll take it out the rest. Please give some arguments for your answers. Thanks

    Read the article

  • How to add a link group to update-alternatives?

    - by Kurtosis
    Is it possible to add a custom link group to update-alternatives that is not already there by default? For example, I want to add Scala and all its supporting binaries as a link group 'scala'. I'm trying using this script, but keep getting the error: update-alternatives: error: unknown argument `' I'm not sure what that means, but after troubleshooting the script a bit with no luck, I'm wondering if update-alternatives has a hard-coded list of link groups, that can't be added to, and that doesn't include scala. PS - any chance someone with higher karma can create an update-alternatives tag? Seems this topic gets a decent number of questions, but no tag for it.

    Read the article

  • Using MLP, how to make a link to the according page in the other languages?

    - by lyle
    Hi all, the question says it all, but here's a bit more detail: I help building a bilingual website using MLP on TextPattern. It's trivial to put a link to the top level page of another language, but how to put a link to the current page in another language? Eg. /en/contact should link to /de/kontakt (the same article in another language). I'm sure there are some variables somewhere that I could put into the template that would be filled with the correct links. Thankx in advance. :)

    Read the article

  • How to configure multiple VLAN's on a lacp link aggregation on openindiana(oi_151a7)?

    - by reco
    i have 4 links aggregated. $ dladm show-link LINK CLASS MTU STATE BRIDGE OVER igb0 phys 1500 up -- -- igb1 phys 1500 up -- -- igb2 phys 1500 up -- -- igb3 phys 1500 up -- -- aggr0 aggr 1500 up -- igb0 igb1 igb2 igb3 i managed to create one VLAN on the aggr0 link: $ dladm show-vlan LINK VID OVER FLAGS vlan1 9 aggr0 ----- if i try to add more i get the following error: $ dladm create-vlan -v 3 -l aggr0 vlan2 dladm: create operation failed: invalid argument

    Read the article

  • Why would autoconf/automake project link against installed library instead of local development libr

    - by Beau Simensen
    I'm creating a library libgdata that has some tests and non-installed programs. I am running into the problem that once I've installed the library once, the programs seem to be linking to the installed version and not the local version in ../src/libgdata.la any longer. What could cause this? Am I doing something horribly wrong? Here is what my test/Makefile.am looks like: INCLUDES = -I$(top_srcdir)/src/ -I$(top_srcdir)/test/ # libapiutil contains all of our dependencies! AM_CXXFLAGS = $(APIUTIL_CFLAGS) AM_LDFLAGS = $(APIUTIL_LIBS) LDADD = $(top_builddir)/src/libgdata.la noinst_PROGRAMS = gdatacalendar gdatayoutube gdatacalendar_SOURCES = gdatacalendar.cc gdatayoutube_SOURCES = gdatayoutube.cc TESTS = check_bare check_PROGRAMS = $(TESTS) check_bare_SOURCES = check_bare.cc (libapiutil is another library that has some helper stuff for dealing with libcurl and libxml++) So, for instance, if I run the tests without having installed anything, everything works fine. I can make changes locally and they are picked up by these programs right away. If I install the package, these programs will compile (it seems like it does actually look locally for the headers), but once I run the program it complains about missing symbols. As far as I can tell, it is linking against the newly built library (../src/libgdata.la) based on the make output, so I'm not sure why this would be happening. If i remove the installed files, the local changes to src/* are picked up just fine. I've included the make output for gdatacalendar below. g++ -DHAVE_CONFIG_H -I. -I.. -I../src/ -I../test/ -I/home/altern8/workspaces/4355/dev-install/include -I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include -I/usr/include/libxml2 -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include -I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -g -O2 -MT gdatacalendar.o -MD -MP -MF .deps/gdatacalendar.Tpo -c -o gdatacalendar.o gdatacalendar.cc mv -f .deps/gdatacalendar.Tpo .deps/gdatacalendar.Po /bin/bash ../libtool --tag=CXX --mode=link g++ -I/home/altern8/workspaces/4355/dev-install/include -I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include -I/usr/include/libxml2 -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include -I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -g -O2 -L/home/altern8/workspaces/4355/dev-install/lib -lapiutil -lcurl -lgssapi_krb5 -lxml++-2.6 -lxml2 -lglibmm-2.4 -lgobject-2.0 -lsigc-2.0 -lglib-2.0 -o gdatacalendar gdatacalendar.o ../src/libgdata.la mkdir .libs g++ -I/home/altern8/workspaces/4355/dev-install/include -I/usr/include/libxml++-2.6 -I/usr/lib/libxml++-2.6/include -I/usr/include/libxml2 -I/usr/include/glibmm-2.4 -I/usr/lib/glibmm-2.4/include -I/usr/include/sigc++-2.0 -I/usr/lib/sigc++-2.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -g -O2 -o .libs/gdatacalendar gdatacalendar.o -L/home/altern8/workspaces/4355/dev-install/lib /home/altern8/workspaces/4355/dev-install/lib/libapiutil.so /usr/lib/libcurl.so -lgssapi_krb5 /usr/lib/libxml++-2.6.so /usr/lib/libxml2.so /usr/lib/libglibmm-2.4.so /usr/lib/libgobject-2.0.so /usr/lib/libsigc-2.0.so /usr/lib/libglib-2.0.so ../src/.libs/libgdata.so -Wl,--rpath -Wl,/home/altern8/workspaces/4355/dev-install/lib creating gdatacalendar Help. :) UPDATE I get the following messages when I try to run the calendar program when I've added the addCommonRequestHeader() method to the Service class after I had installed the library without the addCommonRequestHeader() method. /home/altern8/workspaces/4355/libgdata/test/.libs/lt-gdatacalendar: symbol lookup error: /home/altern8/workspaces/4355/libgdata/test/.libs/lt-gdatacalendar: undefined symbol: _ZN55gdata7service7Service22addCommonRequestHeaderERKSsS4_ Eugene's suggestion to try setting the $LD_LIBRARY_PATH variable did not help. UPDATE 2 I did two tests. First, I did this after blowing away my dev-install directory (--prefix) and in that case, it creates test/.libs/lt-gdatacalendar. Once I have installed the library, though, it creates test/.libs/gdatacalendar instead. The output of ldd is the same for both with one exception: # before install # ldd test/.libs/lt-gdatacalendar libgdata.so.0 => /home/altern8/workspaces/4355/libgdata/src/.libs/libgdata.so.0 (0xb7c32000) # after install # ldd test/.libs/gdatacalendar libgdata.so.0 => /home/altern8/workspaces/4355/dev-install/lib/libgdata.so.0 (0xb7c87000) What would cause this to create lt-gdatacalendar in one case but gdatacalendar in another? The output of ldd on libgdata is: altern8@goldfrapp:~/workspaces/4355/libgdata$ ldd /home/altern8/workspaces/4355/libgdata/src/.libs/libgdata.so.0 linux-gate.so.1 => (0xb7f7c000) libgcc_s.so.1 => /lib/libgcc_s.so.1 (0xb7f3b000) libc.so.6 => /lib/tls/i686/cmov/libc.so.6 (0xb7dec000) /lib/ld-linux.so.2 (0xb7f7d000)

    Read the article

< Previous Page | 62 63 64 65 66 67 68 69 70 71 72 73  | Next Page >