w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
customize system preferences for printing
Someone at Apple helped me by answering all of my questions: Answer at Apple Lists kind regards, Robert

Categories : Osx

Printing a Gridview - how to print n rows on each page using page break
CSS page-break-after not working cross browser I tested page-break-after: always; with ie10 and firefox 22 - it works in both; in Chrome 30 it does not work. So its difficult to tell why it does not work for you in firefox 22. If your user base is mostly IE and firefox (like in our company). This will work: .pagebreak { page-break-after: always; } Apparently the support for css pagebreak is not ideal: pagebreak does not work in chrome or pagebreak not working in all browsers A search for chrome issues lead me to issue 99124 - Printed table content does not respect page-break CSS properties; reported on Oct 4, 2011 and still untriaged: Confirmed, not reviewed for priority and assignment. It seems that printing is just not important. Adding this css did not help either: @medi

Categories : Javascript

how to customize pivot page
You need to change the HeaderTemplate For example like this: <controls:Pivot.HeaderTemplate> <DataTemplate> <StackPanel Margin="0"> <TextBlock FontSize="25" Margin="0" Text="{Binding}"/> </StackPanel> </DataTemplate> </controls:Pivot.HeaderTemplate> <controls:PivotItem Header="item1"> </controls:PivotItem>

Categories : Xaml

Magento - Customize Category Page
I think you can do it by creating static block.For each category you can do static block from admin cms->static block and then at category page where you want to show content of static block base on that current category. you can get current category base on that current category you can call the particular static block and like that you can able to display content base on categories. <?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('yourblockid')->toHtml(); ?> using above you can able to get static block content on template file. and using this you can get current category information <?php echo Mage::getModel('catalog/layer')->getCurrentCategory() ?> one suggestion i would like to give you try to set static block name same as category

Categories : Magento

Can we customize the page indicator in UIPageViewController?
You can use SMPageControl: Github. It works just like the UIPageController but with more customisation possibilities.

Categories : Objective C

Customize drupal search result page
For search results you should use the search-results.tpl.php (all results list) and search-result.tpl.php (single list item) templates. Copy them from ROOT/modules/search folder into your theme folder and override them as you prefer.

Categories : Drupal

Customize Woocommerce Customer Account Page
If you copy the template files from the plugin directory to your theme (or child theme) directory, you can edit them to get what you want. The files in your theme directory will override the stock plugin template. So the original templates are in plugins/woocommerce/templates/myaccount Move the files you want to alter (probably just my-address.php, and/or my-account.php) to themes/my-theme/woocommerce/templates/myaccount/. (NB: that's what the docs say, although I've found that the directory ought to be themes/my-theme/woocommerce/myaccount/—although that could be from conflicting plugins I also have installed.) When you're editing the PHP file, the fields you're after are: $firstname = get_user_meta( $customer_id, 'billing_first_name', true ); $lastname = get_user_meta( $customer_i

Categories : Wordpress

Is there a way to customize the Thinktecture.IdentityServer.v2 login page?
You can always have the RP pass a custom query string param and customize off of that. But you're outside the bounds of WS-Federation at that point. Plus, you must think about the nature of SSO -- the user is really signing into the IdP, not the app. So changing the IdP to look like the app is somewhat disingenuous.

Categories : C#

Angular Bootstrap UI pagination: Can the page number be customize?
Assuming that we are talking about the pagination directive from http://angular-ui.github.io/bootstrap/#/pagination you can limit number of pages displayed in a pagination by using the max-size attribute: <pagination num-pages="noOfPages" current-page="currentPage" max-size="maxSize"></pagination> Here is a working plunk: http://plnkr.co/edit/MKev5wMtu3C5VMq83uFp?p=preview

Categories : Angularjs

customize java script function from particular page when that method is used by many pages
It's going to be a very generic answer that you'll have to modify for your needs, but if the select and all other markup is the same on all pages, which is very unlikely, you have to check the URL to see if you're on a certain page. At the bottom of the page, before </body>, you can do something like : if ( window.location.href.indexOf('/mysite.html') != -1 ) { document.getElementsByTagName('select')[0].value = '1'; } This will set the default value of the first select on the page to 1, and show ABC, if the URL contains mysite.html. FIDDLE

Categories : Javascript

getting blank page when printing with fop 1.1
There seems to be a problem with the AWT renderer (the print renderer uses the AWT renderer) in FOP 1.1. I tried your example using the following as your step 3: fop -atin myfile.at.xml -awt I noticed the same result - a blank page. (NOTE: to get the AWT render to work on Windows, you will need to edit fop.bat so that -Djava.awt.headless=false). I found it strange that no errors were logged to the console, and I couldn't find any bugs reported in FOP's JIRA instance. So I decided to have a play with FOP 1.0. The workaround - download FOP 1.0 instead of FOP 1.1. Use the following as your Step 3: fop -atin myfile.at.xml -print all NOTE: The all argument is used to print all pages. Omitting this argument fails in 1.0, but has been fixed in 1.1. Hope the above is a workable solution f

Categories : Java

second page of the grid comes when printing in asp.net C#
Problem solved. Changed my print button coding to the following. protected void btn_betweeen_date_print_Click(object sender, EventArgs e) { try { grd_between_dates.AllowPaging = false; grd_between_dates.DataSource = (DataTable)ViewState["data_between_dept_wise_male_female"]; grd_between_dates.DataBind(); Session["ctrl"] = pnl_between_dates_grid; ClientScript.RegisterStartupScript(this.GetType(), "onclick", "<script language=javascript>window.open('Print.aspx','PrintMe','height=500px,width=500px,scrollbars=1');</script>"); } catch (Exception ex) { lblmsg.Text = ex.Message; } }

Categories : C#

Printing an ASP.NET Web Site page
If you want to print only a Datalist from a webpage. You can create a Div Name around the datalist and use the below code <script language="javascript"> function printDiv(divName) { var printContents = document.getElementById(divName).innerHTML; var originalContents = document.body.innerHTML; document.body.innerHTML = printContents; window.print(); document.body.innerHTML = originalContents; } </script> Give a div name around the Datalist like this. <div id="PrintDiv"> <asp:DataList ID="DataList1" runat="server"> </asp:DataList> </div> Finally Create a print button. <input type="button" onclick="printDiv('PrintDiv')" value="Print only Datalist!" /> EDIT Your exact code worked f

Categories : Asp Net

Printing rotated text from web page
You can use PHP to generate an image of the rotated text and then print it. The cool thing about images is that it doesn't depend upon the browser at all. There are some solutions (already mentioned in this thread) that work, but are tested only on few latest browsers. This solution doesn't care about the browser as long as the browser can print images, only it bothers about a server that can support PHP5. here's how your PHP file (image_gen.php) should look: <?php // create a 100*100 image $im = imagecreatetruecolor(100, 100); // Write the text $textcolor = imagecolorallocate($im, 0xFF, 0xFF, 0xFF); imagestringup($im, 3, 40, 80, $_GET['text'], $textcolor); header('Content-type: image/png'); // Save the image imagepng($im); imagedestroy($im); ?> See this link... This file takes

Categories : PHP

Printing hidden images, each to a different page of a PDF
I hope I understand Your question. Simply: add a class to everything You want to print, and hide everything else. @media print { * { display: none; } .printable { display: block; }

Categories : Javascript

Printing More than One Page with a Loop From DataGridView
Honestly, I haven't written one line of VB code in my life, but the printing mechanism at a glance seems extremely similar to the Java Printing API. You have to mark the fact that the document you're printing has more pages yourself, using e.hasMorePages = True. Here is a working example: http://www.dreamincode.net/forums/topic/139447-help-with-hasmorepages-please/ Take into consideration the fact that you must always know the place you left off on the former page. Here is another, more realistic example: http://www.dreamincode.net/forums/topic/128639-ehasmorepages-and-logic-to-use-it/

Categories : Vb.Net

{page-break-after: always} not working when printing
I've been dealing with this too. It appears that using the page-break-after property in a break line is a no-no in IE10. According to Internet Explorer’s current documentation supporting CSS 2.1 Section 13.3.1, the page-break-after property does not support line break or header elements. See the remarks in this link: http://msdn.microsoft.com/en-us/library/ie/ms530842. I had to switch my code to use a div with the break after class but that doesn't seem to work in IE9 which is awesome.

Categories : HTML

Printing a page using javascript does not work
The reason is, because you close the window again in you function. Remove newWindow.document.close(); newWindow.close(); The reason for the blank page is, because you have specified an empty string as href value. Remove the hrefattribute from the tag.

Categories : Javascript

Printing HTML to a Page using TweetSharp
Figured it out. Put the code above in different void function, then in the ASP.NET page to put it in the div container I did the following: <div id="tweets"> <% _getTweets(); %> </div> That seemed to fix my problem.

Categories : C#

CSS Printing: @page size ignored IE10
IE 6,7,8,9,10 does not have support for CSS3 "size" property: http://msdn.microsoft.com/en-us/library/hh781508(v=vs.85).aspx Tested in IE11 too. Guess what? Not working.

Categories : CSS

Printing a View within a page of html Drupal 6
Well, I got it to work by updating all modules and core to 6.28 (from 6.26) Don't know why that code would not have worked. I must have had some specific version of some module that conflicted with some other more updated module! Anyway, what worked just fine was: <?php $block = module_invoke('views', 'block', 'view', 'sc_file_view-block_4'); print $block['content']; ?>

Categories : Misc

Blank page when printing BufferedImage in Java
I think the problem might be the high resolution of a printer (as opposed to a screen). As an image is pixel based. That combined with unprintable margins might show nothing. The following should show something double x = pf.getImageableX(); double y = pf.getImageableY(); double w = pf.getImageableWidth(); double h = pf.getImageableHeight(); g2.drawImage(printImg, x, y, w, h, null); And from there to real proportional scaling is a matter of calculation. You might like to set RenderingHints.

Categories : Java

printdocument printing issue only prints first page
You need to set e.HasMorePages = true; when you have more pages to print inside the PrintPageEvent method handler. According to the MSDN documentation the default is false.

Categories : C#

Incorrect text colors when printing HTML page
Check this Fiddle You have to use -webkit-print-color-adjust on the element which you are going to print Also check here to know more about print color adjust https://developer.mozilla.org/en-US/docs/Web/CSS/-webkit-print-color-adjust

Categories : CSS

Rails render JS partial printing code to page
You can try it with some modification : respond_to do |format| format.js end Inside the action and in the view action_name.js.erb write your js code ar if you want to put your erb then use escape_javascript. Check the following link : Why escape_javascript before rendering a partial?

Categories : Javascript

Controlling page breaks when printing to duplex printer
I don't think there is any way to do this with AR currently. It's a great idea though and I'll make sure the ActiveReports team considers this in the future. I'll also ask around and see if anyone else has ideas within GrapeCity/ComponentOne.

Categories : Misc

Error printing specific page range in microsoft word in c++ app
If it works fine in the debug mode, I suggest you write the values ( eg No of pages, page being printed etc ) to a text file. Compare the debug log output , with the release log output. Here's a link which might help you. The link is not in C++, but might guide you in the right way.

Categories : Visual C++

get radio value in printing method in order to transfer some parameters to another page
You don't need to wait for your form to post before you can check to see if they selected a radio button. You can use javascript with the onsubmit listener like so: <form action="modificaPriorita.php" method="post" onsubmit="return validateForm();"> <table> <tr id="format-tabelle"> <th></th> <th><span class="format-celle">TITLE</span></th> <th><span class="format-celle">TYPE</span></th> </tr> <?php $res = GestioneSegnalazione::showSegnalazioni(); function drawTable($res) { $title = $res[0]; $idAuthor = $res[1]; $type = $res[2]; for ($i = 0; $i < $num; $i++) { print "<tr class='row'>

Categories : PHP

Firefox adding page breaks before large div block when printing
Well, Because we don't have live example of your code Unfortunately is very hard to finger out the solution but the good news is I can provide some information about it might works but not sure. Always insert a page break before each element (when printing). You can't use this property for (an empty div) or with (position:absolute;). Before using page-break-before, check if you can use break-before instead. Avoid page break before the element (if possible) so is not guaranteed to work, That is why we ask you to provide some live example to work with it. Try to use page-break-before: inherit; in the second page to till the second page you are part of the first part of the page.(so if you have one table tray to know where is the last part of the first page and add either page-break-before:

Categories : HTML

Magento - blank/empty page whene printing invoice on backend
This is an incompatibility issue between PHP Version 5.4.4-14 and Zend Framwork. Fixed it by commenting out __construct() and __destruct() methods in lib/Zend/Pdf/FileParserDataSource.php // abstract public function __construct(); /** * Object destructor. Closes the data source. * * May also perform cleanup tasks such as deleting temporary files. */ // abstract public function __destruct(); Thank you !

Categories : Magento

what is the difference between printing from a class or returning the output and printing from a function
constructors can't return values. They always return the created object. So you will get in $output the created object of your class sql_output_two_rows and not the string. Restructre the code (maybe static function for formatting or create an extra function for that)

Categories : PHP

Print Natural Sequence with help of 2 threads(1 is printing even and 2'nd is printing odd)
This could be an exercise on threads and lock monitors, but there is nothing to do in parallel that give you advantages. In your code when a thread 1 (OddThread or EvenThread) ends his work and prints out "Odd Thread Finish" (or "Even Thread Finish") the other thread 2 is waiting a notify() or a notifyAll() that never will happen because the first is over. You have to change EvenThread and OddThread adding a synchronized block with a notify call on commShare just after the while cycle. I removed the second if-branch because in this way you don't continue to check the while condition but get a wait on commShare soon. class EvenThread implements Runnable { private Share commShare; private int number = 2; public EvenThread(Share obj) { this.commShare = obj; } p

Categories : Java

Printing items within a list within a list, etc. (Printing nested lists)
The function has no argument called C therefore you cannot pass it a keyword argument called C. Either use directory=... instead or pass it the object as a normal argument. C = ... tree_traverse(C)

Categories : Python

How to redirect /page/index page to /page (and /page to /page/) in Ruby on Rails?
If you don't want to cause a full reload of the page, then you should not use "redirect" in your routes, as that simply issues a browser redirect. That would cause Rails to issue a 301 "Moved Permanently". That essentially means "there is a /page/index route but it's a mistake, we don't use it anymore, please go to /page instead and never come back here." If that is the case then that is what you want to do. If you're using Passenger and will continue to use Passenger, it would be more efficient to put an Apache redirect rule in the htaccess file. It also seems strange that this is even an issue. How have /page/index, /page, and /page/ emerged in the wild as URLs that all point to the same index#index action? What is this index controller? The usual thing is to have, say, a PagesControlle

Categories : Ruby On Rails

Hadoop Pig customize the key name
Just apply a constant field: A = load 'data.txt' using PigStorage(',') as (txt:chararray, num:int); B = group A ALL; C = foreach B generate 'Canada' as country:chararray, SUM(A.num) as total:int;

Categories : Hadoop

How to Customize the SectionHeader
Override tableView:viewForHeaderInSection: in your UITableViewController: - (UIView *) tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section { UIFont *font = [UIFont fontWithName:@"Helvetica Neue UltraLight" size:24]; UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(10, 3, tableView.bounds.size.width - 10, 33)]; label.font = font; label.textColor = [UIColor colorWithRed:1.0 green:1.0 blue:1.0 alpha:0.75]; label.backgroundColor = [UIColor clearColor]; label.text = @"A"; UIView *headerView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, TableView.bounds.size.width, 44)]; [headerView addSubview:label]; [headerView setBackgroundColor:[UIColor clearColor]]; return headerView; } You will need to adju

Categories : IOS

Customize SetPickerDateMode
There's no way of customizing the UIDatePicker apart from that, but you can use a customized UIPickerView for it: UIPickerView Find an example of using it here: http://www.techotopia.com/index.php/An_iOS_5_iPhone_UIPickerView_Example

Categories : Objective C

How to customize log format in git?
Add following in your alias block in .git/config lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --date=relative

Categories : GIT

Customize the Decimal Pad in iOS
you can use inputAccessoryView to add custom controls to the keyboard, this is popular in many apps including google chrome. yourTextField.inputAccessoryView = //yourView having custom buttons for decimal and plus etc

Categories : Iphone

How to customize the pluralization EF6
According to msdn's article Code-Based Configuration (EF6 onwards) section Using DbConfiguration, it is sufficient to simply place your DbConfiguration class in the same assembly as your DbContext class. Nevertheless you can specify it manually, as explained in the article by using either the config file or an annotation in your DbContext. Config file: <entityFramework codeConfigurationType="MyNamespace.MyDbConfiguration, MyAssembly"> <!-- Your EF config --> </entityFramework> Annotation: [DbConfigurationType("MyNamespace.MyDbConfiguration, MyAssembly")] public class MyContextContext : DbContext { } Or [DbConfigurationType(typeof(MyDbConfiguration))] public class MyContextContext : DbContext { } Note: These examples are directly from the article I li

Categories : Entity Framework



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.