instruction stringlengths 0 30k ⌀ |
|---|
Is it possible to add an external pdf into a quarto book and render it into pdf, while still keeping the page numbering of the whole quarto book?
```{{< include figs/examplepdf.pdf >}}``` does not seem to work
```\includepdf[]{examplepdf.pdf}``` seems only to add the pdf document, but 'as is', not layouted in the... |
How to enter external pdf into quarto book while keeping page layout+numbering |
|pdf|r-markdown|pandoc|quarto| |
Actually [@CertainPerformance][1] is incorrect. It should be: `^(0[1-9]|1[0-2])(0[1-9]|1[0-9]|2[0-9]|3[0-1])$`
<!-- begin snippet: js hide: true console: true babel: false -->
<!-- language: lang-js -->
const validate = (str) => {
const yearLimit = 19; // or pass this as an argument if you want
... |
null |
Use the control as below-
@(Html.Kendo().DatePicker()
.Name("FromDate")
.HtmlAttributes(new { onkeydown = "javascript:return false;" })
)
It will disable keyboard typing. Same way other conditions also can be handled. |
null |
I'm trying to configure a rule in AWS WAF to block access to a particular URL except when the request originates from one of a set of trusted IPs. Naturally I'm trying to use IP sets for this.
My network connection appears to switch between a v4 IP and a v6 IP. Ideally I'd include both, but there doesn't seem to be ... |
How to mix IPv4 and IPv6 in AWS WAF IP sets? |
|amazon-web-services|ipv6|waf|amazon-waf| |
{"OriginalQuestionIds":[20620966],"Voters":[{"Id":14122,"DisplayName":"Charles Duffy","BindingReason":{"GoldTagBadge":"bash"}}]} |
{"Voters":[{"Id":3081018,"DisplayName":"Steffen Ullrich"},{"Id":17562044,"DisplayName":"Sunderam Dubey"},{"Id":6324775,"DisplayName":"Jonathan Stellwag"}]} |
As seen in the [screen shot][1], once you add some attributes, set them as variables. You can then chose downloadable and virtual.
The [woo documentation][2] explains it in more detail.
[1]: http://docs.woothemes.com/wp-content/uploads/2012/01/product-variations-4.png
[2]: http://docs.woothemes.com/documen... |
null |
As seen in this image, ![t][1] once you add some attributes, set them as variables. You can then chose downloadable and virtual.
The [woo documentation][2] explains it in more detail.
[1]: https://docs.woothemes.com/wp-content/uploads/2012/01/product-variations-4.png
[2]: http://docs.woothemes.com/document... |
I have a listing details page with a picture-url, title, phonenumber, description and price. On clicking Edit it takes you to a page with an input form for each of those, it also receives the listings previous values and automatically fills them into the input fields using [value]. When I click on the EDIT button, they... |
How can I display order items details in WooCommerce Admin Orders list, when High Performance Orders Storage (HPOS) is enabled? The classic legacy method code no longer works.
Here is the code I was using in legacy mode:
```php
add_action('manage_shop_order_posts_custom_column', 'orders_list_preview_items', 20, 2 ... |
Lets say we have an abstract class with implemented method that HomeComponent extending it and a service with the same code that we inject into component. Is there any difference in our case? if yes what is the differences if no when to use abstract class vs service
abstract class Base {
name: string = ... |
I want to update or insert 1lakhs records into database in a single batch process using some effective design pattern.
Example: I have 1 million records in my table date range from 1/1/2020 to 1/1/2024 and if user updates any transaction in the middle, Ex. 1/1/2022 then based on that particular date I need t... |
I tried upgrading my Firebase project from Spark to Blaze, but kept getting the “Unable to verify your payment information” error.
Tried using 4 different debit cards from India but it still keeps showing the same issue. Could anyone please assist me in resolving this issue? I would greatly appreciate any guidance o... |
Firebase blaze plan Upgrade Issue: Unable to Verify Payment Information |
|firebase|google-cloud-platform| |
null |
It complains because the import is only used when the tests get compiled which isn't the case during a normal compilation so the import remains unused as far as cargo can tell. If you annotate your `tests` module with the `#[cfg(test)]` attribute, it'll stop complaining, because now the import statement and the tests ... |
I suggest you this refactoring:
1) Store all fields in a single array where each row represents a "subform"
2) The index *$i* is no more needed, we will use the array index
3) Add a row:key to each "subform", the array index is a good option since we will remove the rows using *unset()* so the indexes will not ... |
|firebase|google-cloud-firestore| |
You can iterate over the `img` elements that are children of the container with `id="field"`. The filename of an image can be found by using the `subString()` method and using the position of the last backslash character in the string.
<!-- begin snippet: js hide: false console: true babel: null -->
<!-- langua... |
experts im newbie in backend topics and i have 2 flutter apps, one is working perfectly fine when i request the url and the other works only when i do include the port xxxxx:4000/nexus-vote but when removing the port the status code 200 comes and i can see that the index.html is coming in the payload(checked with pos... |
ExpressJS behaves differently when API requested with and without PORT number |
|javascript|flutter|express|nginx| |
The page contains a list of products and a list of filters.
I get query params from url from which I request a list of products. In addition, FilterList also requests a list of attributes of products in this category to create filters, which should change the query string in the url and, using a button, request a new ... |
How do I make my edit form component take values from html in Angular? |
|javascript|html|angular| |
I need a data type, call it `LTEXT` that operates identically to `TEXT` (or possibly CITEXT if that has benefits?) in every way except that it coerces all values to their `lower()` version. So for example:
```
SELECT 'AbC'::LTEXT; => 'abc'
and
SELECT 'AbC'::LTEXT = 'abc'::LTEXT; => true
SELECT 'AbC'::LTEXT =... |
How to create postgres TYPE that automatically converts text to lowercase? |
|postgresql| |
Good night for everyone!
In my app, I'm doing a Horizontal Pager, and the following happens:
When I use `when` inside pageContent, the pages are rendered normally. Code and screenshot are below
```
Scaffold { paddingValues ->
Box(modifier = Modifier
.fillMaxSize()
.padding(... |
|java|hibernate|design-patterns| |
{"Voters":[{"Id":830680,"DisplayName":"Clive"},{"Id":4216641,"DisplayName":"Turing85"},{"Id":139985,"DisplayName":"Stephen C"}],"SiteSpecificCloseReasonIds":[13]} |
Get rid of Generated using the Generated using the NSwag toolchain v11.0.0.0 (Newtonsoft.Json v13.0.0.0) |
Just changing the definition of the function will work
function test(name, age)
{
}
All existing uses of the function will assign to `age` an `undefined` value..
Whenever you use a second parameter it will be assigned to the `age` parameter.
If you want a default value change the funct... |
At the time of this writing, I don't think there's any widely established convention on this yet.
### libc++ case study
There was related discussion with libc++ and SG15. See [this comment in a related LLVM issue ticket in December 2023](https://github.com/llvm/llvm-project/issues/73089#issuecomment-1855338035), ... |
Im generating c# class from json schema with next code:
var schemaName = Path.GetFileNameWithoutExtension(schemaDestination)
.Humanize().Pascalize().Replace("Schema", "");
var json = File.ReadAllText(schemaDestination);
var schema = await JsonSchema.FromJsonAsync(json);
schema.Title... |
I ended up just replacing the variable in js before the container started.
Straight forward, No code changes.
`Dockerfile`
```
FROM nginx:alpine
COPY dist/ /usr/share/nginx/html
COPY docker-entry.sh /entry.sh
RUN chmod +x /entry.sh
EXPOSE 80
ENTRYPOINT ["/entry.sh"]
CMD ["nginx", "-g", "daemon off;"]
```... |
I'm trying to access a Google Drive folder in my React app, but getting an empty array back in the payload. Should I change the fields to fix it? Or is the `q` query wrong?
import axios from 'axios';
import { IImage } from '../interfaces/Image.interface';
const GOOGLE_DRIVE_API_KEY = 'XXX';
... |
How invoke request with updated url query string in RTK query by click button in inner component? |
|reactjs|react-hooks|react-router|rtk-query| |
null |
the difference between useFetch and useAsyncData is that the useAsyncData can employee another data fetching composables that you want to make it server side friendly where as useFetch accept url for fetching data for example
for useFetch
1. useFetch(ur)
for useAsyncData
1. useAsyncData(()=>$fetch(url))
2. u... |
{"Voters":[{"Id":4370109,"DisplayName":"Brian Tompsett - 汤莱恩"},{"Id":3744182,"DisplayName":"dbc"},{"Id":2756409,"DisplayName":"TylerH"}],"SiteSpecificCloseReasonIds":[18]} |
As The Rust Reference documents under [Identifier patterns](https://doc.rust-lang.org/reference/patterns.html#identifier-patterns):
> By default, identifier patterns bind a variable to a copy of or move from the matched value depending on whether the matched value implements [`Copy`](https://doc.rust-lang.org/refere... |
Can't connect to data base in using PHP in my website |
I am using Masstransit library for sending data to Kafka. There is one specific case where I have to send 3 different events to the same Kafka topic. But it looks like Masstransit doesn't support it as it uses **topicName** as a **key** for Dictionary to store Kafka producers:
void IKafkaFactoryConfigurator.Topi... |
MassTransit Kafka producers configure to send several events to the same Kafka topic |
|apache-kafka|rabbitmq|masstransit| |
I joined two tables into one using pandas Concat function. I then put them in a pyplot table. I end up with a table where all the values have 1 decimal. The original tables did not have the decimal before concatenating.
How can I get a table without decimals?
I tried rounding the values in the tables before co... |
How to round values in pyplot table |
|python|matplotlib|rounding| |
null |
Depending on your need, you can use a soft delete pattern.
Add a IsDelete properties on your object.
But as already said by JonasH, it's better to not build an object if it's not valid! |
I am using DefaultTabController for tabbar view but i have many tabs to filter data but its not scrolling and i cant see text of tab
how to make it scrollable so that all tabs can be viewed properly
```
Widget build(BuildContext context) {
final list = ['Furniture', 'Clothe', 'Mobiles', 'Laptop','Accessor... |
Problem using HorizontalPager in Jetpack Compose |
|android|kotlin|android-jetpack-compose|android-jetpack|android-jetpack-compose-material3| |
null |
I noticed in wsl2 Ubuntu 22.04.4, this problem could be solved by running /mnt/c/Windows/System32/wsl.exe through ssh. You can run "code" inside it, the GUI would be shown in windows. |
List comprehensions shouldn't be used for outside side-effects. In this case, use [`enumerate`](https://docs.python.org/3/library/functions.html#enumerate) instead of an outside variable:
```py
h = '10010010' # Undefined in OP example. Just something to enumerate.
table = [[i, bit, None, None ] for i, bit in enum... |
`enter code here`{
using (TransactionScope scope = new TransactionScope())
{var ListTumu1 = entities.tapubilgileri.Where(p => p.kullaniciadi == KullaniciAdiKullanici && p.raporadi == RaporAdiKullanici).ToList();
var ListTumu2 = entities.imardurumubilgileri.Where(p => p.kullaniciadi == KullaniciAdiKullanic... |
Trying to fetch images from a Google Drive folder |
|axios|google-drive-api| |
I have a backend providing a HTTPS Endpoint. It response to a GET Request which is expecting two parameters in the query string part of its URL.
I configured a HTTP API Gateway with a GET method and a route using the above endpoint as the integration target (also with GET method). For the needed parameter I added pa... |
Android 14: D/UsbAlsaDevice( 1571): Unable to set device connection state as INPUT device type is none
its from logcat, when I connect DAC or digital earphone. It appears in some aosp roms. I found nothing useful about this log before. I'm sure DAC is not broke, system can connect it but no sound output. Music softw... |
I have completed implementing the watch function and successfully implemented receiving push notification as well. However, I want to synchronize the calendar after receiving the push notification, but I failed here.
The service is a web application, so I implemented google oauth2 login and callback using servlet.
... |
As far as I understand your question, I think you pretty much explained it to yourself:
> ... the purple stripes indicate the available space within the flex container.
So basically, as far as can be assumed from the second screenshot, your **flex-container** `.btn` has an [intrinsic size][1] that is based on the c... |
Here is my JSON. Its in a file called `file1.txt`
<!-- begin snippet: js hide: false console: true babel: false -->
<!-- language: lang-js -->
{
"foo": [
{
"bar": {
"second": {
"key1": "some/path/to/delimiter1_FIRST_IMPORT... |
I have 8 divs in a div called card-group these cards should expand and there are also little cards which go to the edge this worked then a added more text at the bottom and the on screen fade in but it messed up the :hover effect.
Here is one of the :hover statements there are 8 of these.
<!-- begin snippet: js hid... |
how to make tabbar scrollable when list is big in flutter |
|flutter| |
So I'm using this dataset : https://www.kaggle.com/datasets/madhavmalhotra/journal-entries-with-labelled-emotions
This video as guidance: https://www.youtube.com/watch?v=YyOuDi-zSiI&t=1077s
So I have changed the value of True to 1 and False to 0. I also have removed classes with below 30 instances in it. This be... |

The errors are follows:
```
java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Class android.view.View.getClass()' on a null object reference
at com.android.internal.app.WindowDecorActionBar.getDecorToolbar(Windo... |
null |
I have 8 divs in a div called card-group. These cards should expand and there are also little cards which go to the edge.
This worked then a added more text at the bottom and the on screen fade in but it messed up the :hover effect.
<!-- begin snippet: js hide: false console: true babel: false -->
<!-- languag... |
As the detailed analysis of the issues with your code is given in the answer by *trincot*, this supplementary response tries to simplify the explanation and provides along with an example of binary tree to traverse also more details about the approach using the logical operators `and` and `or` which in Python don't ret... |
Entity Framework, Error when deleting data from multiple tables at the same time |
|c#| |
My goal is to send an image from s3 via whatsapp. If i get the pre-signed url from the aws console, i can send the image as expected, i receive 200 and its shows up on the chat. But when i get the url from aws-sdk on a lambda function, i recceive 200 but the image does not appear in the chat. Both urls i can acess in a... |
S3 pre-signed url not working on whatsapp cloud Api |
|javascript|amazon-web-services|amazon-s3|aws-lambda|whatsapp-cloud-api| |
null |
The short and simple answer is that using `await`, rather than `Wait()` or non-async calls, allows members of your thread pool to work on other tasks while they're waiting for something else to complete.
Think of the thread pool like your employees. Suppose one is given a task, but during the course of that task the... |
|networking|windows-10|windows-7|device-discovery| |
Under settings in the repo created environment Variable Var1.
Below is github actions which will again call another template in different repo
name: GitHub Actions Demo
run-name: ${{ github.actor }} is testing out GitHub Actions
on:
workflow_dispatch:
inputs:
Pass_I... |
null |
{"Voters":[{"Id":1427878,"DisplayName":"CBroe"},{"Id":2802040,"DisplayName":"Paulie_D"},{"Id":17562044,"DisplayName":"Sunderam Dubey"}],"SiteSpecificCloseReasonIds":[13]} |
I'm trying to process a survey containing responses to questions. Some questions allow for multiple choices. I need to evaluate `NA` values for questions where respondents didn't answer. I'm unsure of how to organize the workflow. Could you please advise me on what to do and what steps to take to assess the actual numb... |
Is there a way of extracting portion of a key value between delimiters using jq? |
|jq| |
I did search a bit more, and then it became obvious.
In LocalSettings.php I changed from false to true:
$wgEnotifUserTalk = true;
$wgEnotifWatchlist = true;
I should have search more thoroughly. |
I am trying to upload a file to an existing invoice and running into nothing but problems using the API. I can GET the files OK so my authentication is all OK. Below is my test code and result just saying there is a problem processing my request.
Is this a VBA code or a XERO API issue.
This is my test code to t... |
Xero Upload Invoice file using API |
|vba|api|xero| |